|
| 1 | +--- |
| 2 | +title: "Added a pull request to fastlane to support new screen sizes" |
| 3 | + |
| 4 | +categories: |
| 5 | + - fastlane |
| 6 | +tags: |
| 7 | + - Screensize |
| 8 | + - fastlane |
| 9 | +--- |
| 10 | + |
| 11 | +I have an app that hadn’t been updated for five years, but in September I received a kind review from a user, which asks for deleting feature of search results. |
| 12 | + |
| 13 | +<img src="./assets/img/post/review.png" alt="review" width="500"> |
| 14 | + |
| 15 | +Appreciating the review, I decided to make a small update and release it. |
| 16 | +However, when I tried to upload screenshots through fastlane, it failed with errors. |
| 17 | +~~~ |
| 18 | +[18:11:51]: 🚫 Error: ./fastlane/screenshots/en-US/iPad Pro 13-inch (M4)-1-FillingPAOFieldsOfProductViewController.png - Invalid screen size (Actual size is 2064x2752. See the specifications to fix https://help.apple.com/app-store-connect/#/devd274dd925) |
| 19 | +~~~ |
| 20 | +{: .language-bash} |
| 21 | +But according to [Apple’s documentation](https://developer.apple.com/help/app-store-connect/reference/app-information/screenshot-specifications), the sizes in errors were valid. |
| 22 | +I found that fastlane hadn’t been updated with new devices for about four years, and there were already a few open pull requests related to this. Referring to those, I wrote some code myself and tried again. |
| 23 | +~~~ |
| 24 | +[22:38:33]: fastlane finished with errors |
| 25 | +bundler: failed to load command: fastlane (/Users/jihyunson/.rbenv/versions/3.1.2/lib/ruby/gems/3.1.0/bin/fastlane) |
| 26 | +Spaceship::AppStoreScreenshotError: [!] en-US |
| 27 | +~~~ |
| 28 | +{: .language-bash} |
| 29 | +Then even stranger errors appeared. |
| 30 | +The cause turned out to be that the [App Store Connect API](https://developer.apple.com/documentation/appstoreconnectapi/screenshotdisplaytype) still does not support 6.9’’ and 6.3’’ device sizes. |
| 31 | + |
| 32 | +I was shocked for two reasons: |
| 33 | +1. How could App Store Connect API not support these devices for years? |
| 34 | +2. How could people submit pull requests without actually running the code and verifying that previews upload correctly? |
| 35 | + |
| 36 | +For the first one, I realized that not many developers automate screenshot uploads, and using 6.5’’ screenshots works fine anyway. I submitted feedback to Apple. |
| 37 | +For second, I’m still not sure—maybe I’m missing something. |
| 38 | + |
| 39 | +Anyway, adding new sizes to the existing device types worked fine. So I submitted [a pull request](https://github.com/fastlane/fastlane/pull/29742) |
| 40 | + |
| 41 | +Through this, I learned that fastlane isn’t really a black box. A Gemfile is just like a Podfile or SPM—it’s all code! You can even point it to your local repository like this: |
| 42 | +~~~ |
| 43 | +gem "fastlane", path: '/Users/[...]/Documents/fastlane' |
| 44 | +~~~ |
| 45 | +{: .language-ruby} |
| 46 | + |
| 47 | +Opening black boxes is always fun ❤️🔥 |
0 commit comments