Modify

Opened 18 months ago

Last modified 4 months ago

#22887 new defect

Update snap for Ubuntu

Reported by: taylor.smock Owned by: team
Priority: normal Milestone:
Component: Ubuntu package Version:
Keywords: snap linux Cc: michael.vogt, mvogt

Description (last modified by skyper)

This may be a major source of duplicates for #14596. I'll have to look into updating the snap for current "best practices".

taylor.smock wrote in comment 67 of #14596:

Replying to cserpell@…:

In Ubuntu 22.04, I noticed this started happening when I started using jOSM from snap version, instead of deb version from repository. I didn't change any option by myself, just the defaults.

Thank you for this response.

It gives us a place to start debugging why this problem keeps happening.

  1. The snapcraft (see source:trunk/native/snapcraft.yaml) does not use the start script from source:trunk/native/linux/tested/etc/default/josm. This means that some required start arguments are not added. I don't know if we can use the start script (is JavaFX built into the snap? I don't know, and we kind of require javafx in the start script right now, mostly to avoid bug reports from Microsoft Streetside).
  2. It looks like we haven't really changed the snapcraft.yml file in 5 years, give or take. Are we even following best practices for snaps any more?

I'll see if I can figure out how to build the snap, and then I'll see if I can make the modifications for it.

Attachments (1)

22887.patch (2.5 KB ) - added by taylor.smock 18 months ago.

Download all attachments as: .zip

Change History (15)

comment:1 by skyper, 18 months ago

Description: modified (diff)
Keywords: linux added

Is Ubuntu package the correct component?
Maybe, Michael Vogt (mvo), publisher of the josm snap at Canonical Snapcraft, can help here.

in reply to:  1 comment:2 by taylor.smock, 18 months ago

Cc: michael.vogt added

Replying to skyper:

Is Ubuntu package the correct component?

Maybe, maybe not. AFAIK, snap is only used by Ubuntu and its child distros. Every other distro uses flatpak.

Maybe, Michael Vogt (mvo), publisher of the josm snap at Canonical Snapcraft, can help here.

I'm going to have to ask him (or stoecker, I don't know who actually builds the snap) how the snap is built. It looks like it is either copied up a directory, or whatever version of snapcraft that is used for building has a root directory parameter.

by taylor.smock, 18 months ago

Attachment: 22887.patch added

comment:3 by taylor.smock, 18 months ago

I need someone with a non-arm system to check attachment:22887.patch -- it almost finished on Mac (brew install snapcraft) but failed with a list index out of range error. I don't know if it is the snapcraft.yaml file or just due to it being run on macOS.

comment:4 by stoecker, 18 months ago

The snap isn't anything officially support by JOSM team. I have no idea who provides and builds it.

comment:5 by stoecker, 18 months ago

See #14576 for the source of the file.

comment:6 by skyper, 18 months ago

Cc: mvogt added

comment:7 by taylor.smock, 17 months ago

@mvogt: Can you please look at the patch (attachment:22887.patch) which is for the source:trunk/native/snapcraft.yaml file. If you are no longer using that snapcraft file for building the JOSM snap, please let us know, and we will remove it from our repo.

comment:8 by mvogt, 17 months ago

@taylor.smock It's fine to remove the snapcraft.yaml from the repository. My original intend for this way to have automatic builds of the svn in the snap store "edge" channel. But the builders had issues with building from svn so it never fully materialized.

I am still keeping the snap up to date and love josm but that can all happen outside of the main svn repo :)

comment:9 by taylor.smock, 17 months ago

Thanks for replying.

The major problem we currently have with the snap is that it seems that it doesn't properly set some env variables (see #14596). I was trying to update the snapcraft.yaml file to see if a newer base would fix the issue.

The other problem comes from newer Java versions requiring additional command line arguments (see josm).

But the builders had issues with building from svn so it never fully materialized.

I don't know how you were building from svn, but I found I had to either symlink or copy the snapcraft.yaml to the parent directory (where the build.xml is).

comment:10 by mvogt, 17 months ago

Hey Taylor, I build from https://github.com/mvo5/josm-snapcraft which is based on the original snapcraft.yaml.

Thanks for your patch, I can merge your changes back into my snapcraft.yaml or I can look into porting my changes back into the snapcraft.yaml inside josm svn if that is desired. I am happy either way. Normally I would strongly prefer to have it inside the upstream repo to allow automatic daily edge builds but given that this was problematic with svn (when I last tried) I don't mind either way.

Thanks,

Michael

comment:11 by taylor.smock, 17 months ago

We do have a git mirror at https://github.com/JOSM/josm if the problem is svn.

Since we already have the snapcraft.yaml in the repository, I'd like to either make it work or remove it.

Looking at the josm-snapcraft repository, it looks like it is (at least) partially outdated. #19173 was fixed quite some time ago.

comment:12 by gaben, 4 months ago

JOSM now is the #1 featured snap app across the Snap ecosystem. I just noticed it's lagging behind stable releases.

Last updated
16 March 2024 - latest/stable
16 March 2024 - latest/beta

Is there anything we can do?

Last edited 4 months ago by gaben (previous) (diff)

comment:13 by stoecker, 4 months ago

What about contacting the author? If he releases this with his name prominently placed he should also care for it.

comment:14 by gaben, 4 months ago

He is in the CC of this ticket. I intended to ask him, not the josm team :)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from team to the specified user.
Next status will be 'needinfo'. The owner will be changed from team to taylor.smock.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from team to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.