Skip to content

Being able to handle git managed sources#148

Merged
bugfinder merged 1 commit into
openSUSE:masterfrom
adrianschroeter:master
May 14, 2025
Merged

Being able to handle git managed sources#148
bugfinder merged 1 commit into
openSUSE:masterfrom
adrianschroeter:master

Conversation

@adrianschroeter

Copy link
Copy Markdown
Member

Either when being directly in a git clone (eg. an osc checkout) or when sources has been transfered via a submit request.

We need to be able to handle upstream source submodule here and we can not expect sources in any .osc subdirectory.

Also don't stumble over a .gitmodules file

A more solid way would be to run the download_asset handler instead, but it would take more time and IO to do so.

when having git submodules send via submit request the sources exist already in OBS storage as obscpio, but it avoids enormous disk usage waste on git lfs server due to uncompressed data blobs there.

@bugfinder

Copy link
Copy Markdown
Member

the part about gitmodules is fine
the rest is just assuming files are there, which is wrong.

the spec parser in the build package already knows about createarchive, we just need to add handing this to spec_query when doing print_sources, probably what's in "moveassets" ... if someone can tell me what that field is meant to be

@adrianschroeter

Copy link
Copy Markdown
Member Author

it is testing for existens of either the obscpio file or a directory, not just assuming they are there.

But yes, we can try to use build script parser here for more exact name parsing...

Either when being directly in a git clone (eg. an osc checkout)
or when sources has been transfered via a submit request.

We need to be able to handle upstream source submodule here
and we can not expect sources in any .osc subdirectory.

Also don't stumble over a .gitmodules file

when having git submodules send via submit request the sources
exist already in OBS storage as obscpio, but it avoids enormous
disk usage waste on git lfs server due to uncompressed data blobs
there.
@adrianschroeter

Copy link
Copy Markdown
Member Author

I changed it now avoiding existins tracking, but parsing instead the spec file. Checking if we have a target with a matching name in moveassets here.

We could check in addition if the source also exists either as directory or directory.obspcio , but my time runs out today ....

@bugfinder bugfinder left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

that looks a lot better than the first approach

@bugfinder
bugfinder merged commit 46e976a into openSUSE:master May 14, 2025
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.

2 participants