robbievanleeuwen / section-properties

Analysis of an arbitrary cross-section in python using the finite element method.
https://sectionproperties.rtfd.io
MIT License
412 stars 92 forks source link

Python 3.12 #401

Closed robbievanleeuwen closed 5 months ago

robbievanleeuwen commented 5 months ago

Support Python 3.12!

Currently awaiting rhino3dm for full integration.

dpnova commented 5 months ago

I notice rhino3dm is an optional dep - I'll get the team to try installing/using the lib without it cc @haiderali101

edit: wait, rhino3dm is also listed in the core deps... my bad!

robbievanleeuwen commented 5 months ago

Hi @dpnova, rhino3dm is currently an optional dependency and will not be installed by running pip install sectionproperties. It will only be installed by running pip install sectionproperties[rhino], more info here.

dpnova commented 4 months ago

Hi @dpnova, rhino3dm is currently an optional dependency and will not be installed by running pip install sectionproperties. It will only be installed by running pip install sectionproperties[rhino], more info here.

Circling back to this @robbievanleeuwen - I've been out of python land a bit so I'm not super familiar with newer tools like poetry etc.

when I run the following, rhino3dm builds:

pip install sectionproperties Topologicpy

I see this in the output just before rhino3dm starts building (long build):

Collecting rhino3dm (from rhino-shapley-interop>=0.0.4->sectionproperties)
  Downloading rhino3dm-8.4.0.tar.gz (66.0 MB)

I see in the pyproject.toml for sectionproperties that the dep is an optional, when using the rhino extra in poetry.

Curiously, when i run:

pip install sectionproperties 

it doesn't start building rhino3dm, what am I missing here? :D My guess is that one of the other deps is causing an upgrade of a transitive lib, which is making sectionproperties do something very odd?

In the log I see this:

Collecting sectionproperties
  Using cached sectionproperties-3.2.0-py3-none-any.whl.metadata (6.5 kB)
  Using cached sectionproperties-2.0.3-py3-none-any.whl.metadata (12 kB)

I'm guessing you didn't have rhino3dm as optional in the older version?

robbievanleeuwen commented 4 months ago

Hi @dpnova, in previous versions of sectionproperties, rhino-shapley-interop (and thus rhino3dm) was not optional. Have you tried installing sectionproperties in a fresh virtual environment? It looks like you have some older versions cached in your environment.

If you're not contributing to the project, poetry shouldn't change anything for you - it's mainly used to manage the development dependencies and build the wheel.

dpnova commented 4 months ago

Thanks mate!