Skip to content

Commit 6a8e0c7

Browse files
committed
Merge branch 'RhinoSurface_curvature_fix' of https://github.com/nmaslarinos/compas into RhinoSurface_curvature_fix
2 parents 746acb9 + fbf78ee commit 6a8e0c7

File tree

501 files changed

+12202
-9443
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

501 files changed

+12202
-9443
lines changed

.bumpversion.cfg

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ commit = True
55
tag = True
66

77
[bumpversion:file:setup.py]
8-
search = version='{current_version}'
9-
replace = version='{new_version}'
8+
search = version="{current_version}"
9+
replace = version="{new_version}"
1010

1111
[bumpversion:glob:schemas/*.json]
1212
search = "$compas": "{current_version}"
@@ -17,24 +17,24 @@ search = release = "{current_version}"
1717
replace = release = "{new_version}"
1818

1919
[bumpversion:file:src/compas/__init__.py]
20-
search = __version__ = '{current_version}'
21-
replace = __version__ = '{new_version}'
20+
search = __version__ = "{current_version}"
21+
replace = __version__ = "{new_version}"
2222

2323
[bumpversion:file:src/compas_blender/__init__.py]
24-
search = __version__ = '{current_version}'
25-
replace = __version__ = '{new_version}'
24+
search = __version__ = "{current_version}"
25+
replace = __version__ = "{new_version}"
2626

2727
[bumpversion:file:src/compas_ghpython/__init__.py]
28-
search = __version__ = '{current_version}'
29-
replace = __version__ = '{new_version}'
28+
search = __version__ = "{current_version}"
29+
replace = __version__ = "{new_version}"
3030

3131
[bumpversion:file:src/compas_plotters/__init__.py]
32-
search = __version__ = '{current_version}'
33-
replace = __version__ = '{new_version}'
32+
search = __version__ = "{current_version}"
33+
replace = __version__ = "{new_version}"
3434

3535
[bumpversion:file:src/compas_rhino/__init__.py]
36-
search = __version__ = '{current_version}'
37-
replace = __version__ = '{new_version}'
36+
search = __version__ = "{current_version}"
37+
replace = __version__ = "{new_version}"
3838

3939
[bumpversion:file:CHANGELOG.md]
4040
search = Unreleased

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ insert_final_newline = true
88
indent_style = space
99
indent_size = 4
1010
charset = utf-8
11-
max_line_length = 180
11+
max_line_length = 120
1212

1313
[*.{bat,cmd,ps1}]
1414
end_of_line = crlf

AUTHORS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,4 @@
3434
- Nizar Taha <<[email protected]>> [@nizartaha](https://github.com/nizartaha)
3535
- Gene Ting-Chun Kao <<[email protected]>> [@GeneKao](https://github.com/GeneKao)
3636
- Chen Kasirer <<[email protected]>> [@chenkasirer](https://github.com/chenkasirer)
37+
- Nickolas Maslarinos <<[email protected]>> [@nmaslarinos](https://github.com/nmaslarinos)

CHANGELOG.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,35 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88
## Unreleased
99

1010
### Added
11+
1112
* Added gltf extensions: `KHR_materials_transmission`, `KHR_materials_specular`, `KHR_materials_ior`, `KHR_materials_clearcoat`, `KHR_Texture_Transform`, `KHR_materials_pbrSpecularGlossiness`
1213
* Added `GLTFContent.check_extensions_texture_recursively`
1314
* Added `GLTFContent.get_node_by_name`, `GLTFContent.get_material_index_by_name`
1415
* Added `GLTFContent.add_material`, `GLTFContent.add_texture`, `GLTFContent.add_image`
15-
1616
* Added pluggable `Brep` support with `compas.geometry.brep`.
1717
* Added Rhino `Brep` plugin in `compas_rhino.geometry.brep`.
18+
* Added boolean operations to the `compas_rhino` `Brep` backend.
19+
* Added boolean operation operator overloads in `compas.geometry.Brep`
20+
* Added `format` task using `black` formatter.
21+
* Added a `test_intersection_circle_circle_xy` in the `test_intersections`
22+
* Added split operation to `compas_rhino.geometry.Brep`.
23+
* Added a `RhinoArtist` in `compas_rhino`.
24+
* Added a `RhinoArtist` in `compas_ghpython`.
1825

1926
### Changed
20-
* Based all gltf data classes on `BaseGLTFDataClass`
2127

28+
* Based all gltf data classes on `BaseGLTFDataClass`
2229
* Fixed `Color.__get___` AttributeError.
2330
* Fixed `RhinoSurface.curvature_at` not returning a Vector, but a Rhino SurfaceCurvature class object
31+
* Fixed `cylinder_to_rhino` conversion to match `compas.geometry.Cylinder` location.
32+
* Changed identification of cylinder brep face to non-zero in `compas_rhino.conversions.cylinder.Cylinder`.
33+
* Changed linter to `black`.
34+
* Automatically trigger `invoke format` during `invoke release`.
35+
* Fixed bug in `intersections.intersection_circle_circle_xy` where the Circle's Plane was accessed instead of the centre.
36+
* Fixed bug in `_core.tangent` where the Circle's Plane was accessed instead of the centre.
37+
* Fixed the `test_tangent` to work with a properly defined circle
38+
* `RhinoBrep` serialization works now with surface types other than NURBS.
39+
2440
### Removed
2541

2642

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ In short, this is how that works.
3737
```
3838

3939
5. Start making your changes to the **master** branch (or branch off of it).
40-
6. Auto-format your code using `black -l 180 <path_to_source_file>`.
40+
6. Auto-format your code using `black <path_to_source_file>`.
4141
7. Make sure all tests still pass:
4242

4343
```bash

MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ include AUTHORS.md
1313
include CHANGELOG.md
1414
include requirements.txt
1515
include conftest.py
16+
include pyproject.toml
1617

1718
exclude requirements-dev.txt
1819
exclude pytest.ini .bumpversion.cfg .editorconfig

conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def pytest_ignore_collect(path):
1919
if "matlab" in str(path):
2020
return True
2121

22-
if str(path).endswith('_cli.py'):
22+
if str(path).endswith("_cli.py"):
2323
return True
2424

2525

docs/conf.py

Lines changed: 21 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
import sphinx_compas_theme
1515
from sphinx.ext.napoleon.docstring import NumpyDocstring
1616

17-
sys.path.append(os.path.join(os.path.dirname(__file__), '_ext'))
17+
sys.path.append(os.path.join(os.path.dirname(__file__), "_ext"))
1818

1919
# patches
2020

@@ -28,7 +28,9 @@ def patched_m2r2_setup(app):
2828
app.add_source_suffix(".md", "markdown")
2929
app.add_source_parser(m2r2.M2RParser)
3030
return dict(
31-
version=m2r2.__version__, parallel_read_safe=True, parallel_write_safe=True,
31+
version=m2r2.__version__,
32+
parallel_read_safe=True,
33+
parallel_write_safe=True,
3234
)
3335

3436

@@ -76,7 +78,7 @@ def patched_m2r2_setup(app):
7678
"m2r2",
7779
# "nbsphinx",
7880
"sphinx.ext.autodoc.typehints",
79-
"tabs"
81+
"tabs",
8082
]
8183

8284
# autodoc options
@@ -98,7 +100,7 @@ def patched_m2r2_setup(app):
98100
"rhinoscriptsyntax",
99101
"bpy",
100102
"bmesh",
101-
"mathutils"
103+
"mathutils",
102104
]
103105

104106
autodoc_default_options = {
@@ -112,7 +114,7 @@ def patched_m2r2_setup(app):
112114

113115

114116
def skip(app, what, name, obj, would_skip, options):
115-
if name.startswith('_'):
117+
if name.startswith("_"):
116118
return True
117119
return would_skip
118120

@@ -134,7 +136,7 @@ def setup(app):
134136
"rhinoscriptsyntax",
135137
"bpy",
136138
"bmesh",
137-
"mathutils"
139+
"mathutils",
138140
]
139141

140142
# graph options
@@ -205,7 +207,7 @@ def patched_parse(self):
205207
plot_include_source = False
206208
plot_html_show_source_link = False
207209
plot_html_show_formats = False
208-
plot_formats = ['png']
210+
plot_formats = ["png"]
209211
# plot_pre_code
210212
# plot_basedir
211213
# plot_rcparams
@@ -237,26 +239,26 @@ def patched_parse(self):
237239

238240

239241
def linkcode_resolve(domain, info):
240-
if domain != 'py':
242+
if domain != "py":
241243
return None
242-
if not info['module']:
244+
if not info["module"]:
243245
return None
244-
if not info['fullname']:
246+
if not info["fullname"]:
245247
return None
246248

247-
package = info['module'].split('.')[0]
248-
if not package.startswith('compas'):
249+
package = info["module"].split(".")[0]
250+
if not package.startswith("compas"):
249251
return None
250252

251-
module = importlib.import_module(info['module'])
252-
parts = info['fullname'].split('.')
253+
module = importlib.import_module(info["module"])
254+
parts = info["fullname"].split(".")
253255

254256
if len(parts) == 1:
255-
obj = getattr(module, info['fullname'])
257+
obj = getattr(module, info["fullname"])
256258
mod = inspect.getmodule(obj)
257259
if not mod:
258260
return None
259-
filename = mod.__name__.replace('.', '/')
261+
filename = mod.__name__.replace(".", "/")
260262
lineno = inspect.getsourcelines(obj)[1]
261263
elif len(parts) == 2:
262264
obj_name, attr_name = parts
@@ -266,7 +268,7 @@ def linkcode_resolve(domain, info):
266268
mod = inspect.getmodule(attr)
267269
if not mod:
268270
return None
269-
filename = mod.__name__.replace('.', '/')
271+
filename = mod.__name__.replace(".", "/")
270272
lineno = inspect.getsourcelines(attr)[1]
271273
else:
272274
return None
@@ -281,7 +283,7 @@ def linkcode_resolve(domain, info):
281283

282284
extlinks = {
283285
"rhino": ("https://developer.rhino3d.com/api/RhinoCommon/html/T_%s.htm", "%s"),
284-
"blender": ("https://docs.blender.org/api/2.93/%s.html", "%s")
286+
"blender": ("https://docs.blender.org/api/2.93/%s.html", "%s"),
285287
}
286288

287289
# -- Options for HTML output ----------------------------------------------
@@ -292,7 +294,7 @@ def linkcode_resolve(domain, info):
292294
"navbar_active": "compas",
293295
"package_version": release,
294296
"package_docs": "https://compas.dev/compas/",
295-
"package_old_versions_txt": "https://compas.dev/compas/doc_versions.txt"
297+
"package_old_versions_txt": "https://compas.dev/compas/doc_versions.txt",
296298
}
297299
html_context = {}
298300
html_static_path = sphinx_compas_theme.get_html_static_path()

docs/devguide.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ The procedure for submitting a PR is the following.
7474
Style guide
7575
===========
7676

77-
Please run `black -l 180 <path_to_source_file>` to auto-format your code.
77+
Please run `black <path_to_source_file>` to auto-format your code.
7878

7979
The command ``invoke lint`` runs the entire codebase through ``flake8``.
8080
As described in the `docs <https://flake8.pycqa.org/en/latest/manpage.html>`_,
@@ -88,7 +88,7 @@ https://flake8.pycqa.org/en/latest/user/error-codes.html
8888
The PEP-0008 style guide is available here:
8989
https://www.python.org/dev/peps/pep-0008/
9090

91-
Note that the maximum line length is set to 180 rather 79 in the ``setup.cfg`` of the repo.
91+
Note that the maximum line length is set to 120 rather 79 in the ``setup.cfg`` of the repo.
9292

9393

9494
Naming conventions

docs/tutorial/artists/try_artists_network.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
artist = Artist(network)
1515
artist.draw(
1616
nodecolor={n: Color.pink() for n in [node] + nbrs},
17-
edgecolor={e: Color.pink() for e in edges}
17+
edgecolor={e: Color.pink() for e in edges},
1818
)
1919

2020
Artist.redraw()

0 commit comments

Comments
 (0)