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

cli: improve startup time #693

Merged
merged 1 commit into from
Dec 12, 2024
Merged

cli: improve startup time #693

merged 1 commit into from
Dec 12, 2024

Conversation

skshetry
Copy link
Member

This PR halves the total startuptime from 2.8s to 1.4s, with minimal effort.

There are two more imports that can be reduced: requests, and numpy, that will reduce total time by .3 sec.

The total import time spent is now 1.251s. It's difficult to fix remaining imports because we expose them on top-level imports, and fixing them will require too much duplication/effort or incur runtime costs.

The import trace looks like follows after this PR:

Screenshot 2024-12-12 at 08 40 47

This PR halves the total startuptime from 2.8s to 1.4s, with minimal effort.

There are two more imports that can be reduced: requests, and numpy, that will
reduce total time by .3 sec.

The total import time spent is now 1.251s. It's difficult to fix remaining
imports because we expose them on top-level imports, and fixing them will
require too much duplication/effort or incur runtime costs.
Copy link
Member

@shcheklein shcheklein left a comment

Choose a reason for hiding this comment

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

thanks!

Copy link

codecov bot commented Dec 12, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.35%. Comparing base (b67d599) to head (7bee01b).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #693      +/-   ##
==========================================
+ Coverage   87.32%   87.35%   +0.02%     
==========================================
  Files         113      113              
  Lines       10798    10799       +1     
  Branches     1480     1480              
==========================================
+ Hits         9429     9433       +4     
+ Misses        991      989       -2     
+ Partials      378      377       -1     
Flag Coverage Δ
datachain 87.28% <100.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@skshetry skshetry enabled auto-merge (squash) December 12, 2024 03:19
@skshetry skshetry merged commit 250ce97 into main Dec 12, 2024
33 of 34 checks passed
@skshetry skshetry deleted the improve-startuptime branch December 12, 2024 03:20
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

Successfully merging this pull request may close these issues.

2 participants