File tree Expand file tree Collapse file tree 7 files changed +254
-267
lines changed
Expand file tree Collapse file tree 7 files changed +254
-267
lines changed Original file line number Diff line number Diff line change 11name : Run Tests in Blender
22
3- on :
4- push :
5- branches : ["main"]
6- pull_request :
7- branches : ["*"]
8-
3+ on :
4+ push :
5+ branches : ["main"]
6+ pull_request :
7+ branches : ["*"]
8+
99jobs :
10- build :
11- runs-on : ${{ matrix.os }}
12- strategy :
13- max-parallel : 4
14- fail-fast : false
15- matrix :
16- version : ["4.5 ", "5.0 ", "daily"]
17- os : [macos-14, ubuntu-latest, windows-latest]
18- steps :
19- - uses : actions/checkout@v4
20- - uses : BradyAJohnston/setup-blender@v5
21- with :
22- version : ${{ matrix.version }}
23- - name : Install and Test
24- run : |
25- blender -b -P tests/python.py -- -m pip install -e ".[test ]"
26- blender -b -P tests/run.py -- -vv
10+ build :
11+ runs-on : ${{ matrix.os }}
12+ strategy :
13+ max-parallel : 4
14+ fail-fast : false
15+ matrix :
16+ version : ["5.1 ", "5.2 ", "daily"]
17+ os : [macos-14, ubuntu-latest, windows-latest]
18+ steps :
19+ - uses : actions/checkout@v4
20+ - uses : BradyAJohnston/setup-blender@v5
21+ with :
22+ version : ${{ matrix.version }}
23+ - name : Install and Test
24+ run : |
25+ blender -b -P tests/python.py -- -m pip install -e ".[dev ]"
26+ blender -b -P tests/run.py -- -vv
Original file line number Diff line number Diff line change 1313 max-parallel : 4
1414 fail-fast : false
1515 matrix :
16- version : ["4.5 ", "5.0 "]
16+ version : ["5.1 ", "5.2 "]
1717 os : [macos-latest, windows-latest, ubuntu-latest]
1818 steps :
1919 - uses : actions/checkout@v4
@@ -34,11 +34,11 @@ jobs:
3434
3535 - name : Upload coverage reports to Codecov
3636 uses : codecov/codecov-action@v5
37- if : matrix.os == 'macos-latest' && matrix.version == '5.0 '
37+ if : matrix.os == 'macos-latest' && matrix.version == '5.1 '
3838 with :
3939 token : ${{ secrets.CODECOV_TOKEN }}
4040 name : coverage.xml
4141
4242 - name : Upload coverage reports to Codecov
43- if : matrix.os == 'macos-latest' && matrix.version == '5.0 '
43+ if : matrix.os == 'macos-latest' && matrix.version == '5.1 '
4444 uses : codecov/codecov-action@v3
Original file line number Diff line number Diff line change 11[project ]
22name = " databpy"
3- version = " 0.6.2 "
3+ version = " 0.7.0 "
44description = " A data-oriented wrapper library for the Blender Python API"
55readme = " README.md"
66dependencies = [
7- " numpy>=1.24.0,<2.0 " ,
7+ " numpy" ,
88]
9- requires-python = " ~=3.11 .0"
9+ requires-python = " ~=3.13 .0"
1010keywords = [" blender" , " python" , " numpy" ]
1111maintainers = [
1212 {name =" Brady Johnston" , email =" brady.johnston@me.com" },
@@ -18,7 +18,7 @@ Repository = "https://github.com/bradyajohnston/databpy"
1818Documentation = " https://bradyajohnston.github.io/databpy"
1919
2020[project .optional-dependencies ]
21- bpy = [" bpy>=4.5 " ]
21+ bpy = [" bpy>=5.1 " ]
2222dev = [
2323 " fake-bpy-module" ,
2424 " polars" ,
@@ -38,6 +38,10 @@ members = [
3838[tool .uv .sources ]
3939databpy = { workspace = true }
4040
41+ [[tool .uv .index ]]
42+ name =" dailybpy"
43+ url = " https://bradyajohnston.github.io/dailybpy/"
44+
4145[dependency-groups ]
4246dev = [
4347 " databpy" ,
Original file line number Diff line number Diff line change 1+ import os
12import subprocess
23import sys
3- import os
4-
5- argv = sys .argv
6- argv = argv [argv .index ("--" ) + 1 :]
74
85
96def main ():
7+ argv = sys .argv
8+ argv = argv [argv .index ("--" ) + 1 :]
109 python = os .path .realpath (sys .executable )
11- subprocess .run ([python ] + argv )
10+ run = subprocess .run ([python ] + argv )
11+ if run .returncode != 0 :
12+ print (f"Error: { run .returncode } " )
13+ sys .exit (run .returncode )
1214
1315
1416if __name__ == "__main__" :
15- main ()
17+ try :
18+ main ()
19+ except Exception as e :
20+ print (f"Error: { e } " )
21+ sys .exit (1 )
Original file line number Diff line number Diff line change 1- import pytest
21import sys
32
43argv = sys .argv
1110
1211
1312def main ():
13+ try :
14+ import pytest
15+ except ModuleNotFoundError as e :
16+ print (f"Error: { e } " )
17+ sys .exit (1 )
18+
1419 # run the test suite, and we have to manually return the result value if non-zero
1520 # value is returned for a failing test
1621 if len (argv ) == 0 :
Original file line number Diff line number Diff line change 1- import pytest
2- import numpy as np
1+ import itertools
2+
33import bpy
4+ import numpy as np
5+ import pytest
6+
47import databpy as db
5- import itertools
68
79
810def test_attribute_properties ():
@@ -239,7 +241,7 @@ def test_named_attribute_name():
239241 name = "a" * i
240242 print (f"{ i } letters, name: '{ name } '" )
241243 data = np .random .rand (len (obj .data .vertices ), 3 )
242- if i >= 68 or i == 0 :
244+ if i == 0 :
243245 with pytest .raises (db .NamedAttributeError ):
244246 db .store_named_attribute (obj , data , name )
245247 else :
You can’t perform that action at this time.
0 commit comments