Skip to content

File hash is not updated when changing code in renderChunk #2739

@isidrok

Description

@isidrok
  • Rollup Version: 1.4.1
  • Operating System (or Browser): Linux
  • Node Version: 10.10.0

How Do We Reproduce?

Follow the steps on https://github.com/isidrok/rollup-hashing-bug

Expected Behavior

When code changes in a plugin hook, the file hash should be updated to match the new content.

Actual Behavior

The file hash is not updated with the new content, instead keeps the hash of the original one which can lead to incorrect hashes when modifying the build process but not the source or when some plugin in the build process modifies the source due to external factors.

Note that renaming chunkInfo.fileName from within the plugin will not work since dependent chunks will keep referencing the old fileName.

Let me know if you could use some help for a PR!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions