Skip to content

Commit bcb2a32

Browse files
committed
update pyproject.toml, extraction, serialize
1 parent 28bf897 commit bcb2a32

File tree

6 files changed

+27
-43
lines changed

6 files changed

+27
-43
lines changed

pyproject.toml

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,22 @@
11
[project]
2-
name = "sectionproperties-reporting"
3-
version = "0.1.0"
4-
description = "Add your description here"
2+
name = "sectionproperties-tools"
3+
dynamic = ['version', 'description']
54
readme = "README.md"
65
authors = [
76
{ name = "Connor Ferster", email = "connorferster@gmail.com" }
87
]
98
requires-python = ">=3.13"
109
dependencies = [
11-
"numpydantic>=1.6.9",
1210
"pydantic>=2.11.7",
1311
"sectionproperties>=3.9.0",
1412
]
1513

16-
[project.scripts]
17-
sectionproperties-reporting = "sectionproperties_reporting:main"
18-
1914
[build-system]
20-
requires = ["hatchling"]
21-
build-backend = "hatchling.build"
15+
requires = ["flit_core>=3.2,<4"]
16+
build-backend = "flit_core.buildapi"
2217

2318
[dependency-groups]
2419
dev = [
2520
"ipykernel>=6.29.5",
2621
"ipython>=9.3.0",
27-
"sectionproperties>=3.9.0",
2822
]

src/sectionproperties_reporting/__init__.py

Lines changed: 0 additions & 12 deletions
This file was deleted.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
"""
2+
sectionproperties_tools
3+
"""
4+
5+
__version__ = "0.1.0"
6+
7+
from .extraction import (extract_properties, envelope_stress_results)
8+
from .serialize import (
9+
to_json,
10+
from_json,
11+
dump,
12+
dumps,
13+
dump_dict,
14+
load,
15+
loads,
16+
load_dict,
17+
)

src/sectionproperties_reporting/extraction.py renamed to src/sectionproperties_tools/extraction.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
from __future__ import annotations
22
import numpy as np
33
from typing import Optional
4+
from sectionproperties.analysis.section import Section
5+
from sectionproperties.post.stress_post import StressPost
46

5-
def export_properties(
6-
analysis_section: "sectionproperties.section.Section",
7+
def extract_properties(
8+
analysis_section: Section,
79
subset_to_extract: Optional[str] = None,
810
) -> dict[str, float]:
911
"""
@@ -75,7 +77,7 @@ def export_properties(
7577
return props
7678

7779

78-
def envelope_stress_results(stress_post: "sectionproperties.post.stress_post.StressPost") -> dict[str, dict]:
80+
def envelope_stress_results(stress_post: StressPost) -> dict[str, dict]:
7981
"""
8082
Returns the envelope (min/max/absmax) of the stress results.
8183
"""
File renamed without changes.

uv.lock

Lines changed: 1 addition & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)