Skip to content

Conversation

@mwbrooks
Copy link
Member

CHANGELOG

Fix a bug to allow new projects to be created quicker by using a HTTP HEAD request to check if the template URL exists.

Summary

This pull request updates the URLChecker(http, url) to check if the URL exists using a HEAD request instead of a GET request. This should improve performance, since it will not download the zip to only confirm that the URL is valid.

There should be no change to functionality.

Reviewers

$ lack create asdf
# → Select any app, since all apps are downloaded from template URLS
# → Confirm that the app is created

# Cleanup
$ rm -rf asdf/

Requirements

@mwbrooks mwbrooks added this to the Next Release milestone Aug 11, 2025
@mwbrooks mwbrooks self-assigned this Aug 11, 2025
@mwbrooks mwbrooks requested a review from a team as a code owner August 11, 2025 18:21
@mwbrooks mwbrooks added bug M-T: confirmed bug report. Issues are confirmed when the reproduction steps are documented changelog Use on updates to be included in the release notes semver:patch Use on pull requests to describe the release version increment labels Aug 11, 2025
@codecov
Copy link

codecov bot commented Aug 11, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 63.06%. Comparing base (fcb3cde) to head (ba86f97).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #185   +/-   ##
=======================================
  Coverage   63.06%   63.06%           
=======================================
  Files         212      212           
  Lines       21672    21672           
=======================================
  Hits        13668    13668           
  Misses       6951     6951           
  Partials     1053     1053           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Member

@zimeg zimeg left a comment

Choose a reason for hiding this comment

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

@mwbrooks Super nice find! I'm so glad we're enhancing the slackhttp package with these changes 🎁 ✨

LGTM and testing works well without git available:

$ PATH="" ./bin/slack create -t slack-samples/bolt-js-starter-template
...
📋 Next steps to begin development
   Change into your project with cd jolly-koala-551/
$ PATH="" ./bin/slack create -t slack-samples/bolt-unknown-starter-app
...
🚫 Cannot download Git repository as a .zip archive (git_zip_download_error)

📬 suggestion(non-blocking): Updating the error message to git_repo_not_found or with similar messaging might be interesting!

🚢 note: Please feel free to merge this when the time is right!

@mwbrooks
Copy link
Member Author

Thanks for the quick review @zimeg!

📬 suggestion(non-blocking): Updating the error message to git_repo_not_found or with similar messaging might be interesting!

Interesting suggestion! This error is actually coming from the caller of URLChecker(http, url) so let's hold off and change that error code in another PR so it appears as a separate CHANGELOG entry. 📝

@mwbrooks mwbrooks merged commit 7825a65 into main Aug 11, 2025
6 checks passed
@mwbrooks mwbrooks deleted the mwbrooks-urlchecker-head branch August 11, 2025 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug M-T: confirmed bug report. Issues are confirmed when the reproduction steps are documented changelog Use on updates to be included in the release notes semver:patch Use on pull requests to describe the release version increment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants