Hi @ports,

I am trying to port pydio cells[1,2]. The go.mod file contains
a replace statement:
replace github.com/minio/minio => github.com/pydio/minio 
v0.0.0-20230809141052-8bd460a77d09

This replace statement translates into two lines in the
modules.inc[3,4] file, one pointing to the replacement and one
pointing to the original, in that case with a commit that does
not exist in the original module:

$ egrep 'pydio/minio|minio/minio' modules.inc
        github.com/minio/minio                                                  
         v0.0.0-20230809141052-8bd460a77d09 \ <--- Bad one
        github.com/minio/minio-go/v7                                            
         v7.0.21 \
        github.com/pydio/minio                                                  
         v0.0.0-20230809141052-8bd460a77d09 \ <--- Good one

Since the commit indicated in the modules.inc file does not
exist for github.com/minio/minio, the distfile cannot be
fetched and, e.g., make makesum fails.

>From my poor understanding of the go module system, it seems that
only the github.com/pydio/minio line should be present in the
modules.inc file. Removing the github.com/minio/minio line allows
the port to build.

The same occurs with the other replace statement present in the
go.mod file, but since the distfile can be fetched, it does not
lead to the same issue (maybe this is why it went unnoticed
until now).

Regards,

Hukadan

[1] https://github.com/pydio/cells
[2] https://codeberg.org/hukadan/mystuff/src/branch/main/www/cells
[3] generated using make modgo-gen-modules
[4] see https://gist.github.com/Hukadan/bbfad0e49e95263fb95842b76ed89d12

Reply via email to