Skip to content

x setup doesn't work if ./build is a symlink to a non-existent directory #139800

Closed
@WaffleLapkin

Description

@WaffleLapkin

Summary

x setup crashes when ./build is a symlink to a non-existent directory.

Command used

x setup

Expected behaviour

x should create the directory linked to by the symlink.

Actual behaviour

: ~/p/rust-lib (+ sxq 470 empty); x setup
Traceback (most recent call last):
  File "/home/wffl/prog/rust-lib/x.py", line 53, in <module>
    bootstrap.main()
  File "/home/wffl/prog/rust-lib/src/bootstrap/bootstrap.py", line 1339, in main
    bootstrap(args)
  File "/home/wffl/prog/rust-lib/src/bootstrap/bootstrap.py", line 1301, in bootstrap
    os.makedirs(build.build_dir)
  File "<frozen os>", line 225, in makedirs
FileExistsError: [Errno 17] File exists: '/home/wffl/prog/rust-lib/build'

Operating system

NixOS

HEAD

30f168e

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-pythonArea: python, like bootstrap/CI scripts or linters/formatters, etc.C-bugCategory: This is a bug.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions