Coder Social home page Coder Social logo

amrit3701 / docker-freecad-cli Goto Github PK

View Code? Open in Web Editor NEW
21.0 3.0 10.0 2.83 MB

FreeCAD compile without GUI

Home Page: https://hub.docker.com/r/amrit3701/freecad-cli/

License: MIT License

Dockerfile 0.11% Python 99.89%
docker freecad freecad-cli dockerfile docker-container

docker-freecad-cli's Issues

Initialization of FreeCAD failed for non-root user

Hi,

I'm trying to use your container to generate CAD models.
Since I don't have root permissions on the host system I'm trying to generate the CAD files with ownership set to my user id.

I run the container with the option -u UID:GID. id reports the right IDs for the user.

But when starting python, I get the following output

I have no name!@75d087d8d5b6:/home$ python3.8
Python 3.8.5 (default, Jul 20 2020, 19:48:14)
[GCC 7.5.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
Initialization of FreeCAD failed:
While initializing FreeCAD the following exception occurred: 'Getting HOME path from system failed!'


Please contact the application's support team for more information.

Traceback (most recent call last):
  File "/.startup.py", line 1, in <module>
    import FreeCAD
ImportError: Failed to load FreeCAD module!
>>>

I looked around the forum, but didn't find any solutions.
Do you know of a way to fix this?

Add a workbench

Hi @amrit3701 ,
Thanks for your work !
I'm looking for adding a new workbench to the raw Freecad build (sheet metal).
How would you do that ?

Can't import OpenSCADUtils

C:\>docker run -it amrit3701/freecad-cli python3
Python 3.6.9 (default, Jul 17 2020, 12:50:27)
[GCC 8.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import FreeCAD
>>> import Mesh
>>> import OpenSCADUtils
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/Mod/OpenSCAD/OpenSCADUtils.py", line 31, in <module>
    from exportCSG import mesh2polyhedron
  File "/usr/local/Mod/OpenSCAD/exportCSG.py", line 35, in <module>
    try: import FreeCADGui
ModuleNotFoundError: No module named 'FreeCADGui'

Obviously it has a dependency on the front end, and we're trying to run headless, so I doubt this is going to be an easy problem to solve.

Any general advice on how to get the union of two meshes in an automated fashion, please? I've tried pymesh. I've tried converting to a Part.Shape with makeShapeFromMesh and calling fuse. Neither approach yeilds a mesh which is valid according to or repairs correctly in FreeCAD. The OpenSCAD workbench in FreeCAD does it nicely, but is now putting up a fight when I try to automate it

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.