Skip to content

Fix all instances of using the network after the pull phase#373

Merged
aleasto merged 2 commits into
gnome-46-2404-sdkfrom
wip/core24-build-network
Jul 10, 2026
Merged

Fix all instances of using the network after the pull phase#373
aleasto merged 2 commits into
gnome-46-2404-sdkfrom
wip/core24-build-network

Conversation

@aleasto

@aleasto aleasto commented Jul 9, 2026

Copy link
Copy Markdown
Member

This shall make the build less flaky in launchpad, for riscv64 particularly.

Proof that the previous cargo workaround wasn't working: https://launchpadlibrarian.net/865012403/buildlog_snap_ubuntu_noble_riscv64_gnome-46-2404-sdk_BUILDING.txt.gz

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Snapcraft build recipe to eliminate network access during the build phase (moving it into the pull phase instead), reducing flakiness on Launchpad (notably riscv64).

Changes:

  • Vendor Rust crates during override-pull for librsvg so builds can proceed without reaching out to the network later.
  • Disable mm-common’s Meson use-network option and fetch the required doctag file during override-pull instead.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread snapcraft.yaml Outdated
Comment thread snapcraft.yaml
@aleasto
aleasto force-pushed the wip/core24-build-network branch from 6cb63a8 to aab6688 Compare July 9, 2026 12:53

@sergio-costas sergio-costas left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it, specially the change in mm-common.

@nteodosio

Copy link
Copy Markdown
Contributor

Proof that the previous cargo workaround wasn't working: https://launchpadlibrarian.net/865012403/buildlog_snap_ubuntu_noble_riscv64_gnome-46-2404-sdk_BUILDING.txt.gz

That points to a successful build in which + cargo-1.82 update succeeded. Did you provide the wrong log?

Do you have a link to the build with the changes hereby proposed?

@aleasto

aleasto commented Jul 9, 2026

Copy link
Copy Markdown
Member Author

Proof that the previous cargo workaround wasn't working: https://launchpadlibrarian.net/865012403/buildlog_snap_ubuntu_noble_riscv64_gnome-46-2404-sdk_BUILDING.txt.gz

That points to a successful build in which + cargo-1.82 update succeeded. Did you provide the wrong log?

The build did succeed, but you can see cargo downloading crates during build:

:: + ninja
:: [0/9] Generating rsvg/librsvg-2 with a custom command (wrapped by meson to set env)
::     Updating crates.io index
::  Downloading crates ...
::   Downloaded cast v0.3.0
::   Downloaded adler2 v2.0.1
[...]

Do you have a link to the build with the changes hereby proposed?

Will be provided by github CI in a few

@nteodosio nteodosio left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see.

Once the build output confirms the fix, can you please add an inline comment?

Comment thread snapcraft.yaml
aleasto added 2 commits July 9, 2026 15:43
This project builds with cargo but uses the meson plugin, so we don't get
a local cargo registry by snapcraft for free. Instead, let's manually set
up a vendoring so that crates are correctly only downloaded during pull.

"cargo-1.82 update" doesn't actually help, maybe because the cargo version
changes after rustup.
We cannot rely on the network being available in the build phase.
Download the required file in the pull phase.
@aleasto

aleasto commented Jul 9, 2026

Copy link
Copy Markdown
Member Author

Build log with these changes: https://productionresultssa17.blob.core.windows.net/actions-results/cd161514-876b-4400-a463-adf11b2e29a5/workflow-job-run-cd88a3da-0bca-5ea5-9054-3508f029dc42/logs/job/job-logs.txt?rsct=text%2Fplain&se=2026-07-09T14%3A38%3A45Z&sig=QWHEdqW7p7EcRy1y2ypjkRkduvioSQ1hL%2BFGDHc2ofY%3D&ske=2026-07-09T18%3A03%3A47Z&skoid=ca7593d4-ee42-46cd-af88-8b886a2f84eb&sks=b&skt=2026-07-09T14%3A03%3A47Z&sktid=398a6654-997b-47e9-b12b-9515b896b4de&skv=2025-11-05&sp=r&spr=https&sr=b&st=2026-07-09T14%3A28%3A40Z&sv=2025-11-05

2026-07-09T13:53:28.2128059Z :: + ninja
2026-07-09T13:53:28.2159070Z :: [0/9] Generating rsvg/librsvg-2 with a custom command (wrapped by meson to set env)
2026-07-09T13:53:28.7686770Z ::    Compiling proc-macro2 v1.0.101
2026-07-09T13:53:28.7690800Z ::    Compiling unicode-ident v1.0.18

@aleasto
aleasto force-pushed the wip/core24-build-network branch from aab6688 to 2f13ade Compare July 9, 2026 15:06
@aleasto
aleasto merged commit 307d6a4 into gnome-46-2404-sdk Jul 10, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants