10000 Would you support calling blurb test from unpacked sdist? · Issue #21 · python/blurb · GitHub
[go: up one dir, main page]

Skip to content

Would you support calling blurb test from unpacked sdist? #21

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
hroncok opened this issue Jul 8, 2024 &midd 8000 ot; 3 comments · Fixed by #24
Closed

Would you support calling blurb test from unpacked sdist? #21

hroncok opened this issue Jul 8, 2024 · 3 comments · Fixed by #24

Comments

@hroncok
Copy link
Contributor
hroncok commented Jul 8, 2024

The short story

It would be nice if I could run blurb test from a directory called blurb-1.2.0. Which is the name when I download and unpack the sdist.

Long version

I package blurb for Fedora and I build it from unpackaged sdist. The following code prevents me from running blurb test :

blurb/src/blurb/blurb.py

Lines 831 to 836 in 07bb15c

while not os.path.isdir("blurb"):
old_dir = os.getcwd()
os.chdir("..")
if old_dir == os.getcwd():
# we reached the root and never found it!
sys.exit("Error: Couldn't find the root of your blurb repo!")

It would be great If I did not have to do this:

mkdir blurb
mv tests blurb
cd blurb
blurb test
cd ..
mv blurb/tests .

Would you accept a change that would make this easier for me?

Thanks for blurb!

@hroncok hroncok changed the title Would you support calling blurb tests from unpackeg sdist? Would you support calling blurb test from unpackeg sdist? Jul 8, 2024
@hugovk hugovk changed the title Would you support calling blurb test from unpackeg sdist? Would you support calling blurb test from unpacked sdist? Jul 19, 2024
@hugovk
Copy link
Member
hugovk commented Jul 19, 2024

This sounds reasonable. Although at EuroPython, did you tell me it wasn't so easy?

Perhaps check if the dir begins with "blurb"?

@hroncok
Copy link
Contributor Author
hroncok commented Jul 19, 2024

I assumed it won't be that easy, because it is using paths like this:

directory = "blurb/tests/pass"

Yet maybe that does not really matter. I will check.

@hroncok
Copy link
Contributor Author
hroncok commented Jul 22, 2024

I solved this by removing the blurb/ prefix form the directory attribute: #24

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 a pull request may close this issue.

2 participants
0