Page MenuHomeSoftware Heritage

hypothesis_strategies: Generate only consistent directory entry permissions.
ClosedPublic

Authored by vlorentz on Dec 15 2021, 3:30 PM.

Diff Detail

Repository
rDMOD Data model
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Build is green

Patch application report for D6842 (id=24804)

Rebasing onto 9b21d2d88f...

Current branch diff-target is up to date.
Changes applied before test
commit 6c2115a47b1a14c68b94d0a60bd2aa0227dd49c1
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Wed Dec 15 15:30:50 2021 +0100

    hypothesis_strategies: Generate only consistent directory entry permissions.

See https://jenkins.softwareheritage.org/job/DMOD/job/tests-on-diff/432/ for more details.

olasd added a subscriber: olasd.

I think it makes sense to restrict these a little bit, but we should probably also do it on the DirectoryEntry instantiation, shouldn't we?

Another way to do this would be to properly map the type field out of perms.

swh/model/hypothesis_strategies.py
287

symlinks are 0o120xxx, so I believe we have some of that in the archive too.

This revision is now accepted and ready to land.Dec 20 2021, 3:04 PM
In D6842#178358, @olasd wrote:

I think it makes sense to restrict these a little bit, but we should probably also do it on the DirectoryEntry instantiation, shouldn't we?

In what instantiation?

In D6842#178358, @olasd wrote:

I think it makes sense to restrict these a little bit, but we should probably also do it on the DirectoryEntry instantiation, shouldn't we?

In what instantiation?

When swh.model.model.DirectoryEntry is instantiated, it should reject "wrong" combinations?

This revision was landed with ongoing or failed builds.Dec 21 2021, 2:39 PM
This revision was automatically updated to reflect the committed changes.

Build is green

Patch application report for D6842 (id=24882)

Rebasing onto e34239705e...

First, rewinding head to replay your work on top of it...
Fast-forwarded diff-target to base-revision-435-D6842.
Changes applied before test

See https://jenkins.softwareheritage.org/job/DMOD/job/tests-on-diff/435/ for more details.