Skip to content

Commit

Permalink
Bumping version; undoing changes to Python libraries finding; correct…
Browse files Browse the repository at this point in the history
…ed typehint
  • Loading branch information
DominicDirkx committed Nov 10, 2023
1 parent 2b4555e commit fb89fa6
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.7.3.dev33
current_version = 0.7.3.dev34
commit = True
tag = True
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(\.(?P<release>[a-z]+)(?P<dev>\d+))?
Expand Down
6 changes: 3 additions & 3 deletions cmake/YACMAPythonSetup.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if(_YACMA_PYTHON_MODULE_NEED_LINK)
else()
# NOTE: we need to determine the include dir on our own.
if(NOT YACMA_PYTHON_INCLUDE_DIR)
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from __future__ import print_function\nimport sysconfig\nprint(sysconfig.get_path('purelib'))"
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from __future__ import print_function\nfrom distutils import sysconfig\nprint(sysconfig.get_python_inc())"
OUTPUT_VARIABLE _YACMA_PYTHON_INCLUDE_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
if(_YACMA_PYTHON_INCLUDE_DIR)
set(YACMA_PYTHON_INCLUDE_DIR "${_YACMA_PYTHON_INCLUDE_DIR}" CACHE PATH "Path to the Python include dir.")
Expand Down Expand Up @@ -66,7 +66,7 @@ if(UNIX)
if(NOT YACMA_PYTHON_MODULES_INSTALL_PATH)
# NOTE: here we use this contraption (instead of the simple method below for Win32) because like this we can
# support installation into the CMake prefix (e.g., in the user's home dir).
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from __future__ import print_function\nimport sysconfig\nimport os\nprint(os.path.split(sysconfig.get_path('purelib'))[-1])"
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from __future__ import print_function\nimport distutils.sysconfig\nimport os\nprint(os.path.split(distutils.sysconfig.get_python_lib())[-1])"
OUTPUT_VARIABLE _YACMA_PY_PACKAGES_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
message(STATUS "Python packages dir is: ${_YACMA_PY_PACKAGES_DIR}")
set(YACMA_PYTHON_MODULES_INSTALL_PATH "lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/${_YACMA_PY_PACKAGES_DIR}" CACHE PATH "Install path for Python modules.")
Expand All @@ -78,7 +78,7 @@ elseif(WIN32)
set(_YACMA_PY_MODULE_EXTENSION "pyd")
if(NOT YACMA_PYTHON_MODULES_INSTALL_PATH)
# On Windows, we will install directly into the install path of the Python interpreter.
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from sysconfig import get_path; print(get_path('purelib'))"
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())"
OUTPUT_VARIABLE _YACMA_PYTHON_MODULES_INSTALL_PATH OUTPUT_STRIP_TRAILING_WHITESPACE)
set(YACMA_PYTHON_MODULES_INSTALL_PATH "${_YACMA_PYTHON_MODULES_INSTALL_PATH}" CACHE PATH "Install path for Python modules.")
mark_as_advanced(YACMA_PYTHON_MODULES_INSTALL_PATH)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -672,6 +672,7 @@ void expose_environment(py::module &m) {
.def_property("flight_conditions", &tss::Body::getFlightConditions, &tss::Body::setFlightConditions, get_docstring("Body.flight_conditions").c_str())
.def_property("rotation_model", &tss::Body::getRotationalEphemeris, &tss::Body::setRotationalEphemeris, get_docstring("Body.rotation_model").c_str())
.def_property("system_models", &tss::Body::getVehicleSystems, &tss::Body::setVehicleSystems, get_docstring("Body.system_models").c_str())
.def_property("rigid_body_properties", &tss::Body::getMassProperties, &tss::Body::setMassProperties, get_docstring("Body.rigid_body_properties").c_str())
.def_property_readonly("gravitational_parameter", &tss::Body::getGravitationalParameter, get_docstring("Body.gravitational_parameter").c_str())
.def("get_ground_station", &tss::Body::getGroundStation, py::arg("station_name"))
.def_property_readonly("ground_station_list", &tss::Body::getGroundStationMap );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ void expose_estimation(py::module &m) {
py::arg("initial_covariance"),
py::arg("state_transition_interface"),
py::arg("output_times"),
get_docstring("propagate_covariance").c_str() );
get_docstring("propagate_covariance_split_output").c_str() );

m.def("propagate_covariance",
py::overload_cast<
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ def __setitem__(self, __key: VariableSettings, __value: any) -> None:
"""
return super().__setitem__(self.__read_key(__key), __value)

def __getitem__(self, __key: VariableSettings) -> dict[float: np.ndarray]:
def __getitem__(self, __key: VariableSettings) -> Dict[float: np.ndarray]:
"""
Retrieve the time history corresponding to a dependent variable, identified either by
the dependent variable settings object corresponding to the dependent variable
Expand Down
2 changes: 1 addition & 1 deletion version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.7.3.dev33
0.7.3.dev34

0 comments on commit fb89fa6

Please sign in to comment.