Skip to content

Conversation

@wenyikuang
Copy link
Contributor

@wenyikuang wenyikuang commented Mar 13, 2025

Pull request overview

#5354 (comment)

Background:
And since

https://github.com/conan-io/conan-center-index/blob/master/recipes/libgettext/all/conandata.yml#L1-L4

it's using the https://ftp which keeping raised reject by peers like this:

("Connection broken: ConnectionResetError(54, 'Connection reset by peer')", ConnectionResetError(54, 'Connection reset by peer'))
 
From pure curl:
 
curl --retry 5 -v -SLO https://ftp.gnu.org/pub/gnu/gettext/gettext-0.22.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* Host ftp.gnu.org:443 was resolved.
* IPv6: (none)
* IPv4: 209.51.188.20
*   Trying 209.51.188.20:443...
* Connected to ftp.gnu.org (209.51.188.20) port 443
* ALPN: curl offers h2,http/1.1
* (304) (OUT), TLS handshake, Client hello (1):
} [316 bytes data]
*  CAfile: /etc/ssl/cert.pem
*  CApath: none
* (304) (IN), TLS handshake, Server hello (2):
{ [122 bytes data]
* (304) (IN), TLS handshake, Unknown (8):
{ [81 bytes data]
* (304) (IN), TLS handshake, Certificate (11):
{ [6608 bytes data]
* (304) (IN), TLS handshake, CERT verify (15):
{ [264 bytes data]
* (304) (IN), TLS handshake, Finished (20):
{ [52 bytes data]
* (304) (OUT), TLS handshake, Finished (20):
} [52 bytes data]
* SSL connection using TLSv1.3 / AEAD-AES256-GCM-SHA384 / [blank] / UNDEF
* ALPN: server accepted http/1.1
* Server certificate:
*  subject: CN=ftp.gnu.org
*  start date: Feb  4 02:04:14 2025 GMT
*  expire date: May  5 02:04:13 2025 GMT
*  subjectAltName: host "ftp.gnu.org" matched cert's "ftp.gnu.org"
*  issuer: C=US; ST=Colorado; L=Golden; O=National Renewable Energy Laboratory; CN=fpgate.nrel.gov
*  SSL certificate verify ok.
* using HTTP/1.x
> GET /pub/gnu/gettext/gettext-0.22.tar.gz HTTP/1.1
> Host: ftp.gnu.org
> User-Agent: curl/8.7.1
> Accept: */*
> 
* Request completely sent off
< HTTP/1.1 200 OK
< Date: Thu, 06 Mar 2025 21:17:06 GMT
< Server: Apache/2.4.52 (Trisquel_GNU/Linux)
< Strict-Transport-Security: max-age=63072000
< Last-Modified: Sat, 17 Jun 2023 13:14:41 GMT
< ETag: "18e5760-5fe531590ac53"
< Accept-Ranges: bytes
< Content-Length: 26105696
< Content-Security-Policy: default-src 'self'; img-src 'self' https://static.fsf.org/ https://static.gnu.org/ https://gnu.org/ http://static.fsf.org/ http://static.gnu.org/ http://gnu.org/ http://gnu.org; object-src 'none'; frame-ancestors 'none'; child-src 'self' https://static.gnu.org/ http://static.fsf.org/ http://static.gnu.org/ http://gnu.org;
< X-Frame-Options: DENY
< X-Content-Type-Options: nosniff
< Content-Type: application/x-gzip
< 
{ [7491 bytes data]
* Recv failure: Connection reset by peer
* LibreSSL SSL_read: LibreSSL/3.3.6: error:02FFF036:system library:func(4095):Connection reset by peer, errno 54
  0 24.8M    0  163k    0     0   386k      0  0:01:06 --:--:--  0:01:06  386k
* Closing connection
curl: (56) Recv failure: Connection reset by peer

Proposal solution:

I updated the receipe here:

https://github.com/wenyikuang/conan-libgettext-nrelv2/blob/main/conandata.yml (config file)
https://github.com/wenyikuang/conan-libgettext-nrelv2/blob/main/conanfile.py#L92-L103

to download the source from ftp://ftp insteal of https://ftp.

Pull Request Author

@wenyikuang

  • Model API Changes / Additions
  • Any new or modified fields have been implemented in the EnergyPlus ForwardTranslator (and ReverseTranslator as appropriate)
  • Model API methods are tested (in src/model/test)
  • EnergyPlus ForwardTranslator Tests (in src/energyplus/Test)
  • If a new object or method, added a test in NREL/OpenStudio-resources: Add Link
  • If needed, added VersionTranslation rules for the objects (src/osversion/VersionTranslator.cpp)
  • Verified that C# bindings built fine on Windows, partial classes used as needed, etc.
  • All new and existing tests passes
  • If methods have been deprecated, update rest of code to use the new methods

Labels:

  • If change to an IDD file, add the label IDDChange
  • If breaking existing API, add the label APIChange
  • If deemed ready, add label Pull Request - Ready for CI so that CI builds your PR

Review Checklist

This will not be exhaustively relevant to every PR.

  • Perform a Code Review on GitHub
  • Code Style, strip trailing whitespace, etc.
  • All related changes have been implemented: model changes, model tests, FT changes, FT tests, VersionTranslation, OS App
  • Labeling is ok
  • If defect, verify by running develop branch and reproducing defect, then running PR and reproducing fix
  • If feature, test running new feature, try creative ways to break it
  • CI status: all green or justified

@wenyikuang wenyikuang added the Pull Request - Ready for CI This pull request if finalized and is ready for continuous integration verification prior to merge. label Mar 13, 2025
@wenyikuang wenyikuang requested a review from jmarrec March 13, 2025 19:48
Copy link
Collaborator

@jmarrec jmarrec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok sure, that works.

There is another way which doesn't involve patching the recipe, via core.sources:download_urls in global.conf I think, but that works.
Ideally you'd upload the binaries for that recipe too, but it's small so I don't care much.

Plus, we'll likely upgrade all of our dependencies at some point, maybe when we tackle #5229 so I'm good with this.

Thanks @wenyikuang

@jmarrec jmarrec merged commit be8cd76 into develop Mar 14, 2025
4 of 6 checks passed
@jmarrec
Copy link
Collaborator

jmarrec commented Mar 14, 2025

The ubuntu 24.04 is tripping, I think we should wipe the build dir once.

@jmarrec jmarrec deleted the wenyi/fix-nrel-ci branch March 14, 2025 08:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Pull Request - Ready for CI This pull request if finalized and is ready for continuous integration verification prior to merge.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants