Skip to content
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

Awpy 2 #301

Merged
merged 175 commits into from
Jun 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
175 commits
Select commit Hold shift + click to select a range
ef530d6
new awpy
pnxenopoulos Oct 14, 2023
20b9487
fix
pnxenopoulos Oct 17, 2023
4afdda8
get ticks
pnxenopoulos Oct 20, 2023
1d2d32b
add major events
pnxenopoulos Oct 23, 2023
80e3df7
added docs
pnxenopoulos Oct 24, 2023
aff54fb
save
pnxenopoulos Oct 25, 2023
367ba8c
save
pnxenopoulos Oct 27, 2023
ac89fcc
start tests
pnxenopoulos Oct 27, 2023
a213614
black and tests
pnxenopoulos Oct 27, 2023
a712274
reworking tests, linting
pnxenopoulos Oct 30, 2023
f57cc6a
new cicd without go checking
pnxenopoulos Oct 30, 2023
ca2c8fc
black formatter
pnxenopoulos Oct 30, 2023
4f76fe4
make ruff happy
pnxenopoulos Oct 30, 2023
f1725b5
make pyright happy
pnxenopoulos Oct 30, 2023
6f26274
just for tests to pass
pnxenopoulos Oct 30, 2023
05356a6
weapon fire and flash
pnxenopoulos Nov 3, 2023
208595c
better exceptions
pnxenopoulos Nov 3, 2023
a7d966b
readme
pnxenopoulos Nov 3, 2023
3ff0b8f
more readme changes
pnxenopoulos Nov 3, 2023
342981f
more readme
pnxenopoulos Nov 3, 2023
5b3059f
Readme
pnxenopoulos Nov 3, 2023
b48e364
test rm
pnxenopoulos Nov 3, 2023
1b40f6e
center
pnxenopoulos Nov 3, 2023
df91c2b
more readme fix
pnxenopoulos Nov 3, 2023
4cd24ed
Shrink
pnxenopoulos Nov 3, 2023
1d55ad4
style test
pnxenopoulos Nov 3, 2023
a02859e
maybe
pnxenopoulos Nov 3, 2023
8e7a301
no table
pnxenopoulos Nov 3, 2023
9b787aa
testing
pnxenopoulos Nov 3, 2023
c29e203
Spelling
pnxenopoulos Nov 3, 2023
71b16ba
markdown
pnxenopoulos Nov 3, 2023
b262ae2
ok, you win gh
pnxenopoulos Nov 3, 2023
853c02c
condense
pnxenopoulos Nov 3, 2023
11cd5a5
add 3.10, 3.9
pnxenopoulos Nov 3, 2023
0c0085d
keep workin on stats
pnxenopoulos Nov 15, 2023
84f9181
start of stats module
pnxenopoulos Nov 16, 2023
433eeaa
fix casing
pnxenopoulos Nov 16, 2023
b0276c7
Added sides, kast first pass
pnxenopoulos Nov 18, 2023
eaf0ef2
mucking about
pnxenopoulos Jan 21, 2024
d583a51
continued refactors
pnxenopoulos Jan 22, 2024
875976b
r e f a c t o r
pnxenopoulos Jan 23, 2024
bf41fb7
fixin
pnxenopoulos Jan 23, 2024
22e1b81
more stable
pnxenopoulos Jan 23, 2024
b3b7c5d
save, wip
pnxenopoulos Jan 24, 2024
c8565f6
slim
pnxenopoulos Jan 27, 2024
9a9acf4
fix imports
pnxenopoulos Jan 27, 2024
564b5c5
Reduce imports
pnxenopoulos Jan 27, 2024
842426a
will this delete the cache?
pnxenopoulos Jan 27, 2024
2d32b87
Again
pnxenopoulos Jan 27, 2024
5dd6e59
Remvoe sphinx
pnxenopoulos Jan 27, 2024
3e7f13b
fixing imports
pnxenopoulos Jan 27, 2024
51a34f1
Another fix
pnxenopoulos Jan 27, 2024
2107f0c
vibing
pnxenopoulos Jan 28, 2024
84c2fec
fixin
pnxenopoulos Feb 4, 2024
169bc9d
update dev dependencie
pnxenopoulos Feb 4, 2024
43c4038
fixing rounds
pnxenopoulos Feb 4, 2024
1dbfe86
format
pnxenopoulos Feb 4, 2024
4f194b3
tests, docs
pnxenopoulos Feb 5, 2024
3728464
lintin
pnxenopoulos Feb 5, 2024
7fcc1d3
better readme
pnxenopoulos Feb 5, 2024
3eea116
more readme edits
pnxenopoulos Feb 5, 2024
8dc5033
added faceit demo
pnxenopoulos Feb 6, 2024
e8b6d99
lint
pnxenopoulos Feb 6, 2024
0d2c516
make ruff happy
pnxenopoulos Feb 6, 2024
67dc787
add assist count
pnxenopoulos Feb 6, 2024
24cd882
ruff
pnxenopoulos Feb 6, 2024
b0de5f8
r e o r g
pnxenopoulos Feb 6, 2024
9e13f34
update for eugene
pnxenopoulos Feb 8, 2024
69b958d
i love programming
pnxenopoulos Feb 8, 2024
ebbb251
black
pnxenopoulos Feb 8, 2024
ca5ca93
more formatting
pnxenopoulos Feb 8, 2024
18e8c07
fix test
pnxenopoulos Feb 8, 2024
07a1c97
Awpy2 round parsing (#320)
pnxenopoulos Feb 15, 2024
0ade703
fix column names
pnxenopoulos Feb 15, 2024
a2e9eca
fix to keyerror
pnxenopoulos Feb 15, 2024
f591f07
add round id parsing
pnxenopoulos Feb 17, 2024
2eb8dba
fix
pnxenopoulos Feb 17, 2024
62bde67
fixin
pnxenopoulos Feb 17, 2024
dbb4387
Readme and reqs
pnxenopoulos Feb 17, 2024
abafc89
00_Parsing_a_CS2_Demofile Notebook for Awpy2 Branch (#321)
adisujithkumar Feb 18, 2024
176f188
add bomb plant to round info
pnxenopoulos Feb 18, 2024
4d94417
lint
pnxenopoulos Feb 18, 2024
c94c121
fixin
pnxenopoulos Feb 18, 2024
e061a2a
fix readme
pnxenopoulos Feb 18, 2024
ac6db3a
fix tests
pnxenopoulos Feb 18, 2024
32bd15e
new new
pnxenopoulos Feb 21, 2024
a150ba0
converter tests
pnxenopoulos Feb 21, 2024
1dd194c
fix
pnxenopoulos Feb 21, 2024
88a555a
keep testing parsers
pnxenopoulos Feb 21, 2024
4c584f0
add clan name
pnxenopoulos Feb 21, 2024
5f167aa
kill and damage test on new hltv
pnxenopoulos Feb 21, 2024
cf13609
fix error
pnxenopoulos Feb 21, 2024
12646a2
fix test
pnxenopoulos Feb 21, 2024
cc0bc33
fix lint
pnxenopoulos Feb 21, 2024
16f3f25
rework Demo
pnxenopoulos Feb 22, 2024
18fcc35
change to new demoparser version
pnxenopoulos Mar 3, 2024
060e760
added basic rounds
pnxenopoulos Mar 7, 2024
e9dff48
update python reqs, fix bugs, add logging
pnxenopoulos Mar 24, 2024
0d4927e
Cleaning damages_df (#324)
hojlund123 Mar 26, 2024
c6b558f
adr, begin kast, round number, version
pnxenopoulos Mar 26, 2024
82d6414
fix ruff
pnxenopoulos Mar 26, 2024
c7956eb
fix demo version
pnxenopoulos Mar 26, 2024
c5604c8
remove version
pnxenopoulos Mar 26, 2024
703c2d7
fixing bugs
pnxenopoulos Mar 28, 2024
d1bffc5
Merge branch 'awpy2' of https://github.com/pnxenopoulos/awpy into awpy2
pnxenopoulos Mar 28, 2024
f006be7
fix
pnxenopoulos Mar 28, 2024
e8db2a6
removed map_bombsites
pnxenopoulos Mar 28, 2024
37de290
stats module, impact and rating
pnxenopoulos Mar 29, 2024
2e23f15
test release
pnxenopoulos Apr 3, 2024
47609bb
maybe
pnxenopoulos Apr 3, 2024
82ca3c1
testing actions
pnxenopoulos Apr 3, 2024
7287443
Test push
pnxenopoulos Apr 3, 2024
449ed99
fix python versions
pnxenopoulos Apr 3, 2024
b0c6957
on push
pnxenopoulos Apr 3, 2024
d3f4303
fix artifact names
pnxenopoulos Apr 3, 2024
e213e21
better workflow
pnxenopoulos Apr 3, 2024
42bcb39
Spelling
pnxenopoulos Apr 3, 2024
11656e3
mov e to token
pnxenopoulos Apr 3, 2024
7695e16
test repository
pnxenopoulos Apr 3, 2024
d4c14d1
actions env
pnxenopoulos Apr 3, 2024
1cbfd88
Test
pnxenopoulos Apr 3, 2024
4e496d1
test new flow
pnxenopoulos Apr 3, 2024
2bc8383
rc
pnxenopoulos Apr 3, 2024
baacda6
push
pnxenopoulos Apr 3, 2024
1f34482
version change
pnxenopoulos Apr 3, 2024
fe92f64
will this work
pnxenopoulos Apr 3, 2024
4db1136
testin
pnxenopoulos Apr 3, 2024
5e6c336
no deps
pnxenopoulos Apr 3, 2024
f1f2f4d
actual no deps
pnxenopoulos Apr 3, 2024
1e14d66
better pydantic model
pnxenopoulos Apr 3, 2024
54bf297
Fix formatting
pnxenopoulos Apr 3, 2024
b276964
release workflow
pnxenopoulos Apr 3, 2024
fecf0d8
fix on triggers
pnxenopoulos Apr 3, 2024
d554e32
correct environment
pnxenopoulos Apr 3, 2024
cc23c2a
fix failed tests
pnxenopoulos Apr 3, 2024
0fdd6a9
fix test imports
pnxenopoulos Apr 3, 2024
513f48d
small change
pnxenopoulos Apr 4, 2024
84c3f52
update reqs and readme
pnxenopoulos Apr 18, 2024
a5b531e
Readme center and armor
pnxenopoulos Apr 18, 2024
324acf2
more readme changes
pnxenopoulos Apr 18, 2024
d7b6375
only build on code or test changes
pnxenopoulos Apr 18, 2024
8793ecf
pyproject changes
pnxenopoulos Apr 18, 2024
0666dbf
Armor value
pnxenopoulos Apr 18, 2024
84c2ab8
fixing armor, adding demo code
pnxenopoulos Apr 18, 2024
f8d32de
fixing img
pnxenopoulos Apr 18, 2024
efae1f2
img md
pnxenopoulos Apr 18, 2024
03d784f
more img md
pnxenopoulos Apr 18, 2024
967adcd
forget gif
pnxenopoulos Apr 18, 2024
20705e7
fixing bad round parsing
pnxenopoulos Apr 24, 2024
39ccde1
change to 2.0.0-alpha
pnxenopoulos Apr 24, 2024
ccd57d4
fixing stats, linting
pnxenopoulos Apr 24, 2024
4d7c216
Update parsers.py (#328)
hojlund123 May 17, 2024
ba13c4c
make pathing changes
pnxenopoulos May 19, 2024
db4c202
no more pydantic
pnxenopoulos May 19, 2024
d32fd6f
max timeout
pnxenopoulos May 19, 2024
63d9a37
linting, start of viz module
pnxenopoulos May 23, 2024
9a0f20e
workflow
pnxenopoulos Jun 2, 2024
bffcb66
move to poetry
pnxenopoulos Jun 2, 2024
45cf646
ci stuff
pnxenopoulos Jun 2, 2024
f280c22
test
pnxenopoulos Jun 2, 2024
2978c4d
cleanup
pnxenopoulos Jun 2, 2024
25843fd
fix build
pnxenopoulos Jun 2, 2024
22731f0
fixing
pnxenopoulos Jun 2, 2024
0d387d3
fix install
pnxenopoulos Jun 2, 2024
7471891
remove coverage
pnxenopoulos Jun 2, 2024
d962d0c
poetry stuff
pnxenopoulos Jun 2, 2024
e98a666
clean up workflow
pnxenopoulos Jun 2, 2024
0e135aa
clean naming
pnxenopoulos Jun 2, 2024
21e7c40
rename and cleanup
pnxenopoulos Jun 2, 2024
a05ef3f
update pyproject.toml
pnxenopoulos Jun 3, 2024
4b0cecd
ruffing it up
pnxenopoulos Jun 3, 2024
3c6eea8
docs.yml
pnxenopoulos Jun 3, 2024
e5d507a
release
pnxenopoulos Jun 3, 2024
ea3e977
fix release
pnxenopoulos Jun 3, 2024
d3466cf
more release changes
pnxenopoulos Jun 3, 2024
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
97 changes: 51 additions & 46 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,16 @@ name: build
on:
push:
branches: [main, dev]
paths:
- "awpy/**"
- "tests/**"
- "pyproject.toml"
pull_request:
branches: [main]
paths:
- "awpy/**"
- "tests/**"
- "pyproject.toml"

jobs:
build:
Expand All @@ -15,75 +23,72 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.11"] #, "3.12-dev"]
go-version: ["1.18", "1.19", "1.20"]
python-version: ["3.9", "3.10", "3.11", "3.12"]
timeout-minutes: 15
steps:
- name: Checkout awpy library
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Cache test demos
id: cache-demos
uses: actions/cache@v3
uses: actions/cache@v4
env:
cache-name: cache-demos
with:
# demos are downloaded to
# and looked for in `{repo}/tests`
# demos are downloaded to and looked for in `{repo}/tests`
path: ${{ github.workspace }}/tests/*.dem
# Invalidate the cache if the file containing the demo urls
# has changed.
# Invalidate the cache if the file containing the demo urls has changed.
key: cache-test-demos-${{ hashFiles('**/test_data.json') }}
# Care with this: If a demo changes but the name remains the same
# then this could cause issues.
# So do not do that!
# then this could cause issues. So do not do that!
restore-keys: cache-test-demos-

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go-version }}
cache-dependency-path: awpy/parser/go.sum

- name: Set up Python
uses: actions/setup-python@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
cache-dependency-path: |
requirements.txt
tests/requirements.txt
poetry.lock
pyproject.toml

- name: Installation
- name: Install Poetry
uses: abatilo/actions-poetry@v2
- name: Setup a local virtual environment for poetry
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r tests/requirements.txt

- name: Check formatting with black
uses: psf/black@stable
poetry config virtualenvs.create true --local
poetry config virtualenvs.in-project true --local

- name: Lint with ruff
uses: chartboost/ruff-action@v1
- uses: actions/cache@v4
name: Cache awpy dependencies
with:
version: 0.0.291
path: ./.venv
key: venv-${{ matrix.os }}-${{ matrix.python-version }}-${{ hashFiles('poetry.lock') }}

- name: Typecheck with pyright
uses: jakebailey/pyright-action@v1
with:
version: 1.1.329
- name: Install awpy
run: |
poetry install --no-interaction

- name: Thorough check with pylint
run: pylint awpy
- name: Formatting + Lint
run: |
poetry run ruff check . --fix --exit-zero
poetry run ruff check .

# - name: Run pyright
# run: poetry run pyright

- name: Test with pytest
# - name: Thorough check with pylint
# run: poetry run pylint awpy

- name: Test
run: |
coverage run -m pytest --durations=10
coverage report -m
coverage json
coverage html
poetry run coverage run -m pytest --durations=10
poetry run coverage report -m
poetry run coverage json
poetry run coverage html

- name: Archive code coverage results
uses: actions/upload-artifact@v3
with:
name: code-coverage-report
path: htmlcov/
# - name: Archive code coverage results
# uses: actions/upload-artifact@v4
# with:
# name: code-coverage-report-${{ github.run_id }}
# path: htmlcov/
4 changes: 2 additions & 2 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/setup-python@v4
- uses: actions/checkout@master
- uses: actions/setup-python@v5
- uses: actions/checkout@v4
with:
fetch-depth: 0 # otherwise, you will failed to push refs to dest repo
- name: Build and Commit
Expand Down
43 changes: 0 additions & 43 deletions .github/workflows/go_code.yml

This file was deleted.

50 changes: 50 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Build and Publish to PyPI

on:
push:
tags:
- 'release-v*.*.*'

jobs:
build-and-release:
runs-on: ubuntu-latest
environment:
name: test-release-pypi
permissions:
id-token: write

steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.9"

- name: Install Poetry
uses: abatilo/actions-poetry@v2
- name: Setup a local virtual environment for poetry
run: |
poetry config virtualenvs.create true --local
poetry config virtualenvs.in-project true --local
poetry config repositories.testpypi https://test.pypi.org/legacy/

- name: Install awpy
run: |
poetry install --no-interaction

- name: Publish to test PyPI
run: |
poetry publish --repository testpypi --username __token__ --password ${{ secrets.TEST_PYPI_API_TOKEN }}

- name: Check that installation from test PyPI passes
run: |
poetry add awpy --source testpypi

- name: Publish to PyPI
run: |
poetry publish --username __token__ --password ${{ secrets.PYPI_API_TOKEN }}

- name: Check that installation from PyPI passes
run: |
poetry add awpy
111 changes: 0 additions & 111 deletions .golangci.yaml

This file was deleted.

5 changes: 0 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,3 @@ repos:
"-rn", # Only display messages
"-sn", # Don't display the score
]
- repo: https://github.com/golangci/golangci-lint
rev: v1.54.2
hooks:
- id: golangci-lint
entry: bash -c 'cd awpy/parser && golangci-lint run --new-from-rev HEAD --fix'
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-20.04
os: ubuntu-22.04
tools:
python: "3.11"
# You can also specify other tool versions:
Expand Down
Loading
Loading