Discussion: State of the snap (Snap Packaging)
Re: Discussion: State of the snap (Snap Packaging)
- Investigated PYTHONPATH issues and proposed a fix: https://forum.freecadweb.org/viewtopic.php?f=10&t=47335
- Fixed matplotlib issues: FEM meshes, runs calculix-ccx and displays results just fine.
Next up:
- Investigate problems related to xdg-desktop-portal. Things like "Cannot rename project file to backup file" etc.
- Expose FreeCADCmd as an app
- Test more workbenches with runtime dependencies
- Fixed matplotlib issues: FEM meshes, runs calculix-ccx and displays results just fine.
Next up:
- Investigate problems related to xdg-desktop-portal. Things like "Cannot rename project file to backup file" etc.
- Expose FreeCADCmd as an app
- Test more workbenches with runtime dependencies
Last edited by ppd on Mon Jun 08, 2020 4:17 pm, edited 1 time in total.
Re: Discussion: State of the snap (Snap Packaging)
Awesome progress, thanks for the update!
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Re: Discussion: State of the snap (Snap Packaging)
As it turns out, xdg-desktop-portal offers no support for accessing neighbouring files at the moment: https://github.com/flatpak/xdg-desktop- ... issues/463
This means we don't have rights to write backup files (BackupPolicy) in the same directory as the project file. However, xdg-desktop-portal is supposedly also getting support for not proxying files to which the user has access anyway. This would then solve the problem without any downside.
(see https://forum.snapcraft.io/t/improving- ... port/13035)
This means we don't have rights to write backup files (BackupPolicy) in the same directory as the project file. However, xdg-desktop-portal is supposedly also getting support for not proxying files to which the user has access anyway. This would then solve the problem without any downside.
(see https://forum.snapcraft.io/t/improving- ... port/13035)
Re: Discussion: State of the snap (Snap Packaging)
Updates:
- OpenSCAD & Elmer are now included from their respective PPA
Remaining Problems:
- xdg-desktop-portal-gtk + Qt file dialog leads to setDefaultSuffix being ignored (https://github.com/flatpak/xdg-desktop- ... issues/191)
- recent files show the proxied filepaths. Not great, not horrible.
Some Ideas:
- Provide doc in separate snap that connects to the main snap (this interface would need to be versioned)
- Investigate printing support
I filed an issue about enforcing a suffix for the filename in xdg-desktop-portal: https://github.com/flatpak/xdg-desktop- ... issues/496
- OpenSCAD & Elmer are now included from their respective PPA
Remaining Problems:
- xdg-desktop-portal-gtk + Qt file dialog leads to setDefaultSuffix being ignored (https://github.com/flatpak/xdg-desktop- ... issues/191)
- recent files show the proxied filepaths. Not great, not horrible.
Some Ideas:
- Provide doc in separate snap that connects to the main snap (this interface would need to be versioned)
- Investigate printing support
I filed an issue about enforcing a suffix for the filename in xdg-desktop-portal: https://github.com/flatpak/xdg-desktop- ... issues/496
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Discussion: State of the snap (Snap Packaging)
Hi PPD,
This is vejmarie. If you want get access to the developper account for the snap, I got no issue with that, just give me a mail address. When I created that snap, the organizations were not existing this was at the very early stage of snap, and I made it with canonical engineering as to push the boundaries of snap.
I do have a use case which prohibits me to switch the snap to core18, as I am running it into a docker environment in server mode for the CADCloud project. core18 is not able to run in docker properly (or I never had been able to make it work properly). A lot of the build is outdated, but the way to build it is upstreamed in FreeCAD. Loved to learn your modifications.
I mostly built all dependencies and didn't relied on a specific distro packages, because at the early stage of the initial built, OCCT 7 was not the predefined version into ubuntu. it was still relying I think on OCE 6.7 or something like that.
Normally the font are included into the snap, and there is a lot of end users with it. I still has bugs I agree, but works in many cases. I have a 0.19 build. I never made a nightly build as I was lacking a system to make that build.
vejmarie
This is vejmarie. If you want get access to the developper account for the snap, I got no issue with that, just give me a mail address. When I created that snap, the organizations were not existing this was at the very early stage of snap, and I made it with canonical engineering as to push the boundaries of snap.
I do have a use case which prohibits me to switch the snap to core18, as I am running it into a docker environment in server mode for the CADCloud project. core18 is not able to run in docker properly (or I never had been able to make it work properly). A lot of the build is outdated, but the way to build it is upstreamed in FreeCAD. Loved to learn your modifications.
I mostly built all dependencies and didn't relied on a specific distro packages, because at the early stage of the initial built, OCCT 7 was not the predefined version into ubuntu. it was still relying I think on OCE 6.7 or something like that.
Normally the font are included into the snap, and there is a lot of end users with it. I still has bugs I agree, but works in many cases. I have a 0.19 build. I never made a nightly build as I was lacking a system to make that build.
vejmarie
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Discussion: State of the snap (Snap Packaging)
I can set it up without any issue, if somebody could explain me how to setup such organization.ppd wrote: ↑Tue May 26, 2020 1:04 pm I have a few problems with FreeCAD's snap package (https://snapcraft.io/freecad) and would like to start a discussion on how to improve from here. Experience wise, I'm the author of SolveSpace's snap packaging (https://snapcraft.io/solvespace).
- Organization: The snap is not published by an organization account (i.e. "FreeCAD"), but by Jean-Marie Verdun (vejmarie). It should be transferred to such an account and vejmarie should then be added as a collaborator. Additionally, more than one person should have access to its administration interfaces to increase the bus factor.
It is hidden into FreeCAD source tree. I use Vagrant to build the snap. https://github.com/FreeCAD/FreeCAD/tree/master/vagrant. Latest version is here https://github.com/CADCloud/CADCloud/tr ... er/freecad. It is crappy and not up to date with latest snap technology, but this was the way we successfully built the first version.
That is weird. Which desktop environment do you use ? The snap is currently built with gnome in mind. Probably a mistacke from me
I got it with XFce setup
True it needs a rework to support 0.18, but up to now it was not working, due to some limitations I faced with core18. (I think this was related to OpenGL issue, and some people who are running it into a VM. I for sure met issues with running it into Docker, but that is a very specific use case)ppd wrote: ↑Tue May 26, 2020 1:04 pm
[*] Packaging: The snap is not based on a current platform (core18 or soon core20) and does not employ best practice for desktop applications, e.g. using the kde-neon extension for an updated Qt and not having to bundle all Qt libraries. I couldn't test any further, for the reasons outlined above.
I wanted to make it happens, but never had the time to do it on my system at home. Last but not least, I made it for a month at the beginning and people were complaining about the download implication it had for the one using a daily built. I think monthly shall be the target.
ppd wrote: ↑Tue May 26, 2020 1:04 pm
[/list]
I have sketched an implementation in my FreeCAD fork: https://github.com/ppd/FreeCAD/tree/snap/snap and it works well for me. Obviously, much can be cleaned up and improved. But for that we need a better structure and some healthy discourse.
I'm open for suggestions and criticism.
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Discussion: State of the snap (Snap Packaging)
By the way you made a great job ! Snap has drastically evolved from the early days I created the original snap. We probably need to get rid of the vagrant directory from the master tree, include your snapcraft and use the snapcraft.io build system. I kept updating my initial work without looking too much at snapcraft evolution.
I didnt' checked, but did your build works on Xenial ? There is still a ton of people using that version of Ubuntu (which explained why I didn't used the PPA packages and rebuilt a lot of the stuff by hand). Last time I tested core18 (was probably last year), the desktop integration was broken.
I am using a lot netgen. Might be good if it could work with the snap either. I can have a look to how integrate it into your work if needed.
As to create an organization for the snap we still need a general email address to point to and manage it. I can add you to the current freecad snap as an admin like I did for krimitzi.
I didnt' checked, but did your build works on Xenial ? There is still a ton of people using that version of Ubuntu (which explained why I didn't used the PPA packages and rebuilt a lot of the stuff by hand). Last time I tested core18 (was probably last year), the desktop integration was broken.
I am using a lot netgen. Might be good if it could work with the snap either. I can have a look to how integrate it into your work if needed.
As to create an organization for the snap we still need a general email address to point to and manage it. I can add you to the current freecad snap as an admin like I did for krimitzi.
- Ivo Cavalcante
- Posts: 3
- Joined: Wed Jun 24, 2020 12:46 am
Re: Discussion: State of the snap (Snap Packaging)
Hi guys,
First of all: congrats for the work you've doing. Improving Snap package is something I've been expecting for a long time. Even tried to Snap it myself, but couldn't get beyond successfully compiling (it takes a lot of other adjustments I didn't know how to do).
I understand you're going to merge ppd's job into "official" Snap as soon the job is complete, right? I'm asking because right now there's the old version and ppd's one (I know it says it's temporary, but thought about asking anyway).
Thanks!
First of all: congrats for the work you've doing. Improving Snap package is something I've been expecting for a long time. Even tried to Snap it myself, but couldn't get beyond successfully compiling (it takes a lot of other adjustments I didn't know how to do).
I understand you're going to merge ppd's job into "official" Snap as soon the job is complete, right? I'm asking because right now there's the old version and ppd's one (I know it says it's temporary, but thought about asking anyway).
Thanks!
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Discussion: State of the snap (Snap Packaging)
Hi,
I just have made an update on the process to update the snap. Can people give a try to the build which is available into snapcraft as beta (0.19 build through snap install freecad --channel=latest/beta), The constraint I have is to build on Xenial currently for many reason, I will be switching to newer ubuntu as soon as I got everything which works. The challenge with newer build is that they might be buggy with older distro, and Xenial is still the mostly used. The snapcraft.yaml is inspired from ppd work, and include the required lib to build on Xenial.
The build process is public and based on vagrant -> Generate library Deb file -> Snapcraft, which is slightly different from ppd, who is building with the snap tools directly.
https://github.com/CADCloud/CADCloud/tr ... er/freecad
I can upstream that process into freecad. To build an image you need vagrant https://www.vagrantup.com/ from hashicorp, clone the repo and kick vagrant up. It shall be building everything and the snap will be into the VM within the /home/vagrant/Result directory.
Let me know if the 0.19 build is suitable for your need ?
vejmarie
I just have made an update on the process to update the snap. Can people give a try to the build which is available into snapcraft as beta (0.19 build through snap install freecad --channel=latest/beta), The constraint I have is to build on Xenial currently for many reason, I will be switching to newer ubuntu as soon as I got everything which works. The challenge with newer build is that they might be buggy with older distro, and Xenial is still the mostly used. The snapcraft.yaml is inspired from ppd work, and include the required lib to build on Xenial.
The build process is public and based on vagrant -> Generate library Deb file -> Snapcraft, which is slightly different from ppd, who is building with the snap tools directly.
https://github.com/CADCloud/CADCloud/tr ... er/freecad
I can upstream that process into freecad. To build an image you need vagrant https://www.vagrantup.com/ from hashicorp, clone the repo and kick vagrant up. It shall be building everything and the snap will be into the VM within the /home/vagrant/Result directory.
Let me know if the 0.19 build is suitable for your need ?
vejmarie
- vejmarie
- Posts: 713
- Joined: Mon Jan 04, 2016 4:52 pm
- Location: Somewhere between France, USA and Taiwan
- Contact:
Re: Discussion: State of the snap (Snap Packaging)
Hello Ivo,Ivo Cavalcante wrote: ↑Wed Jun 24, 2020 12:53 am Hi guys,
First of all: congrats for the work you've doing. Improving Snap package is something I've been expecting for a long time. Even tried to Snap it myself, but couldn't get beyond successfully compiling (it takes a lot of other adjustments I didn't know how to do).
I understand you're going to merge ppd's job into "official" Snap as soon the job is complete, right? I'm asking because right now there's the old version and ppd's one (I know it says it's temporary, but thought about asking anyway).
Thanks!
Welcome to FreeCAD forum. Can you give a try to the latest build I made ?
vejmarie