Skip to content

Add support for SHA-256-hashed repositories #271

Open

Description

@flamenco687

Hi!

Does by any chance this plugin fail to work with SHA256 repositories?

ERROR: core/variant/variant_utility.cpp:1098 - GitPlugin: Could not initialize repository. Error -1: unsupported extension name extensions.objectformat in godot-git-plugin\src\git_plugin.cpp:GitPlugin::_initialize#L695
ERROR: Could not initialize GitPlugin

This is the error I get when trying to turn on VSC for my project. Note that my project was initialized with default Git source control metadata; I then deleted the .git folder to initialize a new repository using git init --object-format=sha256.

I have tried to turn on VSC for an older project that uses default SHA1 and it works as expected.

Activity

  1. Calinou commented on Mar 11, 2025

    @Calinou
    Member

    I doubt alternative hashing methods were implemented in this plugin, so only SHA-1 will work for now. Feel free to open a pull request to add support for SHA-256 🙂

    For context, Git added support for alternative hashing methods following SHAttered in 2017. It's still not the default for new repositories in 2025 though, as many Git hosts and programs don't support it.

  2. changed the title [-]No support for SHA256[/-] [+]Add support for SHA-256-hashed repositories[/+] on Mar 11, 2025
  3. flamenco687 commented on Mar 12, 2025

    @flamenco687
    Author

    I doubt alternative hashing methods were implemented in this plugin

    That's good to know. I was kind of aware of the risks of using a relatively new hashing method, though didn't expect it would actually be this bad. For now, I'll better keep using SHA-1 since too many things are just broken with 256.

    Maybe one day I'll beat my fear to C++ to try and contribute to the project 😛

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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