Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validation failing for podspecs with Twitter URLs #10291

Closed
1 task done
CFKevinRef opened this issue Dec 18, 2020 · 4 comments
Closed
1 task done

Validation failing for podspecs with Twitter URLs #10291

CFKevinRef opened this issue Dec 18, 2020 · 4 comments
Milestone

Comments

@CFKevinRef
Copy link

Our CI job validating podspecs started failing yesterday with:

 - WARN  | url: The URL (https://twitter.com/awscloud) is not reachable.
...
[!] AmazonIVSPlayer did not pass validation, due to 1 warning (but you can use `--allow-warnings` to ignore it).

Looked into the history around similar issues like #9049. curl with the CocoaPods user agent no longer returns 200. Other/empty user agents didn't help.

Twitter recently cut off some basic HTTP GET capabilities, which seems related as this coincides with our CI job failing.

Report

What did you do?

Run pod lib lint

What did you expect to happen?

Validation to pass, no changes were made recently to the podspec in question.

What happened instead?

Validation fails due to twitter URLs being "not reachable"

CocoaPods Environment

I don't have access to this at the moment, but the CI was using CocoaPods 1.9.3 and then 1.10.0 with no change in behavior.

@dnkoutso
Copy link
Contributor

There are two workarounds here, --allow-warnings or remove the twitter website until a proper fix is done.

@paulb777
Copy link
Member

We temporarily remove the twitter link for our pod lib lint testing in CI. See here.

fxm90 added a commit to fxm90/GradientProgressBar that referenced this issue Dec 20, 2020
fxm90 added a commit to fxm90/LightweightObservable that referenced this issue Dec 20, 2020
fxm90 added a commit to fxm90/GradientLoadingBar that referenced this issue Dec 20, 2020
ElfSundae added a commit to ElfSundae/ESFramework that referenced this issue Jan 2, 2021
fjcaetano added a commit to fjcaetano/ReCaptcha that referenced this issue Jan 4, 2021
Cocoapods lib linting is throwing a warning on the twitter link used in the Podspec file. Warnings need to be allowed while this issue isn't fixed: CocoaPods/CocoaPods#10291
tobihagemann added a commit to cryptomator/cryptolib-swift that referenced this issue Jan 5, 2021
tobihagemann added a commit to cryptomator/cloud-access-swift that referenced this issue Jan 5, 2021
mukeshthawani added a commit to Kommunicate-io/Kommunicate-iOS-SDK that referenced this issue Jan 19, 2021
mukeshthawani added a commit to Kommunicate-io/Kommunicate-iOS-SDK that referenced this issue Jan 19, 2021
@saghul
Copy link

saghul commented Feb 2, 2021

Just ran into this myself. IMHO having the push command fail because a social media URL fails is too defensive. It could be transient failure, rate limit or what have you, but tat the end of the day, it doesn't compromise how the pod works. Please consider removing that check for the social media URLs. Thanks for all the work in CocoaPods! ❤️

@dnkoutso dnkoutso added this to the 1.10.2 milestone Feb 2, 2021
@dnkoutso dnkoutso closed this as completed Feb 2, 2021
OdNairy added a commit to mapbox/mapbox-events-ios that referenced this issue Feb 5, 2021
Ticket with details: CocoaPods/CocoaPods#10291
Expected CocoaPods release with fixes: 1.10.2
OdNairy added a commit to mapbox/mapbox-events-ios that referenced this issue Feb 5, 2021
Ticket with details: CocoaPods/CocoaPods#10291
Expected CocoaPods release with fixes: 1.10.2
OdNairy added a commit to mapbox/mapbox-events-ios that referenced this issue Feb 5, 2021
Ticket with details: CocoaPods/CocoaPods#10291
Expected CocoaPods release with fixes: 1.10.2
@manavo
Copy link

manavo commented Feb 6, 2021

I think the reason for this with Twitter specifically is because they seem to do User Agent checks to see if a browser is supported:

% curl -H 'User-Agent: Cocoapods' https://twitter.com/cocoapods
<!DOCTYPE html>
<html dir="ltr" lang="en">
<head>
  <meta charset="utf-8" />
  <meta name="viewport"
    content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0,viewport-fit=cover" />
  <style>
    body {
      -ms-overflow-style: scrollbar;
      overflow-y: scroll;
      overscroll-behavior-y: none;
    }

    .errorContainer {
      background-color: #FFF;
      color: #0F1419;
      max-width: 600px;
      margin: 0 auto;
      padding: 10%;
      font-family: Helvetica, sans-serif;
      font-size: 16px;
    }

    .errorButton {
      margin: 3em 0;
    }

    .errorButton a {
      background: #1DA1F2;
      border-radius: 2.5em;
      color: white;
      padding: 1em 2em;
      text-decoration: none;
    }

    .errorButton a:hover,
    .errorButton a:focus {
      background: rgb(26, 145, 218);
    }

    .errorFooter {
      color: #657786;
      font-size: 80%;
      line-height: 1.5;
      padding: 1em 0;
    }

    .errorFooter a,
    .errorFooter a:visited {
      color: #657786;
      text-decoration: none;
      padding-right: 1em;
    }

    .errorFooter a:hover,
    .errorFooter a:active {
      text-decoration: underline;
    }

  </style>
</head>
<body>
  <div class="errorContainer">
    <img width="46" height="38"
      srcset="https://abs.twimg.com/errors/logo46x38.png 1x, https://abs.twimg.com/errors/logo46x38@2x.png 2x"
      src="https://abs.twimg.com/errors/logo46x38.png" alt="Twitter" />
    <h1>This browser is no longer supported.</h1>
    <p>
      Please switch to a supported browser to continue using twitter.com. You can see a list of supported browsers in our Help Center.
    </p>
    <p class="errorButton"><a href="https://help.twitter.com/using-twitter/twitter-supported-browsers">Help Center</a>
    </p>
    <p class="errorFooter">
      <a href="https://twitter.com/tos">Terms of Service</a>
      <a href="https://twitter.com/privacy">Privacy Policy</a>
      <a href="https://support.twitter.com/articles/20170514">Cookie Policy</a>
      <a href="https://legal.twitter.com/imprint">Imprint</a>
      <a href="https://business.twitter.com/en/help/troubleshooting/how-twitter-ads-work.html">Ads info</a>
      © 2021 Twitter, Inc.
    </p>

  </div>
</body>
</html>

If we used a "normal" browser user agent, the Twitter validation should work.

Not submitting a PR for this since it's debatable if that's a good idea, just thought I'd mention why this is happening!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants