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

Feat: New pricing system #332

Merged
merged 36 commits into from
Feb 18, 2025
Merged

Feat: New pricing system #332

merged 36 commits into from
Feb 18, 2025

Conversation

philogicae
Copy link
Member

@philogicae philogicae commented Jan 31, 2025

Jira: ALEPH-393, ALEPH-397, ALEPH-400

Depends on this PR on SDK

Self proofreading checklist

  • The new code clear, easy to read and well commented.
  • New code does not duplicate the functions of builtin or popular libraries.
  • An LLM was used to review the new code and look for simplifications.
  • New classes and functions contain docstrings explaining what they provide.
  • All new code is covered by relevant tests.
  • Update TODO lines for PROD

Changes

ALEPH-393

  • Add/use new price aggregate
  • New compute units system
  • Display selection table and checkout for each entity
  • Add/use new cost endpoint

ALEPH-397

  • Split flows (between 80/20)
  • Handle legacy flow/VM older than wallet_community_timestamp

ALEPH-400

  • Fetch CRN list from new program endpoint
  • Select an available GPU and then filter CRNs
  • Display GPU pricing and compute units selection

Changes on programs

  • internet field not passed on program creation. It's an important fix since internet=True doubles the cost
  • Display program pricing

Other changes

  • New aleph pricing <entity> cmd + tests
  • New aleph instance gpu cmd
  • Deprecate and remove firecracker hypervisor for instances
  • Upgrade CI action versions

Screenshots

Community flow

Creation

image

Deletion

image

Pricing table previews

aleph pricing <entity>

image

GPU

image

Programs

image

@philogicae philogicae self-assigned this Jan 31, 2025
Copy link

codecov bot commented Feb 3, 2025

Codecov Report

Attention: Patch coverage is 59.52756% with 257 lines in your changes missing coverage. Please review.

Project coverage is 57.56%. Comparing base (78bc789) to head (56b9817).
Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
src/aleph_client/commands/instance/__init__.py 58.12% 46 Missing and 21 partials ⚠️
src/aleph_client/commands/instance/network.py 50.00% 38 Missing and 7 partials ⚠️
src/aleph_client/commands/pricing.py 77.01% 32 Missing and 8 partials ⚠️
src/aleph_client/commands/utils.py 7.69% 36 Missing ⚠️
src/aleph_client/commands/instance/display.py 18.60% 35 Missing ⚠️
src/aleph_client/commands/program.py 59.64% 19 Missing and 4 partials ⚠️
src/aleph_client/commands/account.py 64.00% 7 Missing and 2 partials ⚠️
src/aleph_client/commands/files.py 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #332      +/-   ##
==========================================
+ Coverage   57.21%   57.56%   +0.35%     
==========================================
  Files          18       18              
  Lines        2779     3113     +334     
  Branches      377      430      +53     
==========================================
+ Hits         1590     1792     +202     
- Misses        982     1103     +121     
- Partials      207      218      +11     

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

@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from 174fc10 to 7b4a7a0 Compare February 3, 2025 18:22
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from e970707 to 6728dc6 Compare February 6, 2025 20:28
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch 3 times, most recently from 623e570 to 0d42186 Compare February 11, 2025 11:28
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from 7254a66 to d598d5c Compare February 11, 2025 16:32
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from 1fd3007 to 665a741 Compare February 11, 2025 19:13
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from faf31c1 to d9426e3 Compare February 13, 2025 15:09
@philogicae philogicae requested a review from nesitor February 14, 2025 17:25
@philogicae philogicae marked this pull request as ready for review February 14, 2025 17:30
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from 53d0b76 to e2275c3 Compare February 17, 2025 11:43
@philogicae philogicae requested review from olethanh and 1yam February 17, 2025 12:24
@aleph-im aleph-im deleted a comment from github-actions bot Feb 18, 2025
@philogicae philogicae force-pushed the feat-new-pricing-and-flow branch from ee2dc75 to 56b9817 Compare February 18, 2025 17:23
@philogicae philogicae merged commit fbae1c4 into master Feb 18, 2025
14 checks passed
@philogicae philogicae deleted the feat-new-pricing-and-flow branch February 18, 2025 17:34
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