Skip to content

4.5.0-dev.20211029: Does not throw error TS5056: Cannot write file '/to/file/path' because it would be overwritten by multiple input files.Β #46577

Closed

Description

Bug Report

πŸ”Ž Search Terms

TS5056, because it would be overwritten by multiple input files

πŸ•— Version & Regression Information

  • This changed between versions 4.4.4 and 4.5.0-dev.20211029

⏯ Playground Link

This bug cannot be reproduced in Playground.

πŸ’» Code

Sorry this bug cannot be reproduced as as simple code. Instead of I've created the repository to reproduce this.

https://github.com/sosukesuzuki-sandbox/ts-4.5-bug-reproduce

πŸ™ Actual behavior

Does not throw error TS5056: Cannot write file '/to/file/path' because it would be overwritten by multiple input files.

πŸ™‚ Expected behavior

Throw error TS5056: Cannot write file '/to/file/path' because it would be overwritten by multiple input files.

Activity

  1. DanielRosenwasser commented on Oct 29, 2021

    @DanielRosenwasser
    Member

    Isn't this correctly catching an error now? The two files would have been written to the same output .js file.

    If you're using a bundler or similar build tool that does its own compilation, you can turn --noEmit on and this should work.

  2. andrewbranch commented on Oct 29, 2021

    @andrewbranch
    Member

    The error is correct and it’s gone from 4.5.

    It seems that matchFiles is broken in 4.5; it’s not picking up the TSX file at all. Investigating.

  3. locked as resolved and limited conversation to collaborators on Oct 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

BugA bug in TypeScriptFix AvailableA PR has been opened for this issue

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions