Version History and Release Notes¶
Releases of SaaS Pegasus: The Django SaaS Boilerplate are documented here.
This release is a large overhaul of the React example that ships with Pegasus, including:
- Add url-routing support. Add/edit URLs now update and are linkable. This also enables back button support
- Add validation feedback missing / bad data
- Switch all components from using classes to hooks
- Split React components out into their own files
- Better loading UX
Other minor updates:
- Upgrade Django to 3.0.10 (3.1 support coming soon)
- Generate random
SECRET_KEYfor each new installation
- Upgrade to Bulma 0.9.0
- Remove some spacing utility classes in favor of the ones that ship with bulma
Existing Pegasus users will need to upgrade the installer to run this.
pip install --upgrade pegasus-installer>=0.0.2
Sep 4, 2020
- Fix default styling of number inputs in forms.
Trueif using email confirmation.
- Fix issue building front end on certain newer versions of nodejs/npm
Aug 31, 2020
This release fixes an edge case in the invitation accepting logic that didn’t work if a user left the page and came back later.
Aug 24, 2020
A minor maintenance/bugfix release:
- Fixed a bug in the invitation workflow that prevented invitations from being accepted
when creating accounts with social logins. Note that this requires changing the
- Make site branding in the navigation stay visible on mobile devices
- Make it more obvious that
settings.SECRET_KEYshould be overridden.
- Upgrade Django to 3.0.9
Aug 21, 2020
Stripe billing portal integration is here!
You can now use Stripe’s new customer portal to manage subscriptions in your app.
Supported operations and configurations include upgrading and downgrading subscriptions, subscription cancellations (both immediately, and at period end), and subscription renewals.
Additional documentation can be found in the subscription docs.
Details and other changes:
- Added “manage billing” redirect to subscription pages if you have an active subscription, which goes to the Stripe customer portal
- Added webhook functionality to sync subscription changes and cancellations made via the Stripe portal
- Removed built-in “Cancel” option and supporting code.
stripelibrary to version
- Removed the
CustomUserobject. Customers are now always accessed via their associated subscriptions.
- Removed a lot of no-longer-needed code from
SubscriptionModelMixinrelated to accessing subscriptions from the
.customerfield. References to
.stripe_subscriptionshould be changed to simple
- Fixed bug where “http://” was incorrectly assigned to the
Site.domainobject (fixes issues using
July 16, 2020
This is another minor release with mostly small fixes and updates to the front end.
- Added number formatting of Salary to object demo examples
- Fixed styling of number form inputs
- Removed unnecessary imports from
- Fixed incorrect distinction between
- Upgraded React to 16.13.1
- Moved React object lifecycle example to a
- Started splitting up React object lifecycle demo into multiple files, and refactoring it to use hooks
- Renamed React object lifecycle example bundle file from
- Removed unused “bower_components” exclusion in
July 13 2020
- Upgraded to Django 3.0.7
- Fixed display of renewal details in subscription view to work with the latest Stripe Prices API
- Added ability to resend invitations from the team management page
- Added sort order to team member list (by email address)
- Cleaned up teams JavaSript (removed console logging statements, updated whitespace, removed commented code)
June 30 2020
- Improved styling of Stripe credit card forms in subscriptions and payments examples
- Fixed bug in subscriptions where not setting a default plan prevented the UI from working
- Fixed bug where monthly subscriptions would not work if you also had a quarterly or 6-month price configured
- Changed the order of some examples in examples home page and navigation
June 17 2020
- Added ability to cancel a Subscription directly on the site. Demo (you have to create a Subscription first)
- Don’t show password change links if using social authentication (thanks Yaniv!)
June 11, 2020
Pegasus now supports Vue.js!
Version 0.7 adds a Vue.js implementation of the Object Lifecycle demo so you can start with a foundation of either React or Vue.
Membershipinline admin editing to
Teamsmodel (thanks Troels!)
- Added a few more spacing utility css classes to
June 5, 2020
0.23.0to fix installation version conflict.
May 26, 2020
This release begins the move of Pegasus’s core functionality out of the “pegasus” app and into the user-defined apps. It’s a relatively big release from a code perspective, although there is very little new / changed in terms of functionality.
The philosophy guiding this change is “your starting code base should be as understandable as possible”.
Historically, Pegasus has attempted to separate “Pegasus-owned” files from “user-owned” files. The thinking behind this structure was that Pegasus upgrades and code merges would be as easy as possible since - in theory - users would not need to modify anything in the “Pegasus-owned” space.
In practice, the line between “Pegasus-owned” and “user-owned” was fuzzy, and customizing an application often required editing files in the “Pegasus-owned” space. So the benefit was not realized.
Furthermore, this split caused the initial codebase to be more confusing, since core functionality was split across two places.
Changes related to the restructure above include:
- Moved all base templates from
- Moved team invitation templates from
pegasus/apps/usersand all related code into
pegasus/apps/teamsand all related code into
pegasus/apps/componentsand moved code to more specific apps - further details below
promote_user_to_superusermanagement command into
bootstrap_subscriptionsmanagement command into
google_analytics_idcontext processor to web app
meta.pyfrom pegasus app to web app
apps.utilsand moved most of
apps.utilsand renamed to
- Removed unused
stripe.pyfile (replacing functionality with equivalent functions in
- Removed “Pegasus” from API url names
- Moved non-example JS imports out of
- Lowercased (and kebab-cased) all JS file names for consistency
- Moved sass files from
- Renamed various layout classes, e.g.
pegasus-message, etc. to
- Removed unused
Other changes and fixes include:
- Fix accepting an invitation if you’re already signed in
- Remove subscription-related fields from team and user models if not using subscriptions
- Only ship base migration files for users and teams, and have applications manage their own migrations
- Improved checks and error-handling around accepting invitations multiple times
bulmaCSS framework to
npm audit fixto update other JS library dependencies
pip-toolsand other packages in
- Added backend check to the payments example, to show how to prevent client-side exploits
- Improve password reset email copy
- Externalized styles on progress bar demo
A Note on Database Migrations¶
Historically, Pegasus has shipped with complete database migrations. However, maintaining a set of migrations for each possible Pegasus configuration or forcing all configurations to use the same DB schema has proven unwieldy. Thus, migrations are now expected to be managed outside of Pegasus.
For new users, the only change is that prior to running
./manage.py migrate for the first time,
you must first run
For existing users you can either keep your current migrations folder, or you can run
./manage.py makemigrations and then
./manage.py migrate --fake. If you have changed the user or team
models, then you should keep your current folder.
May 19, 2020
- Fixed default Postgres DB settings (adding host and port)
- Removed Stripe webhooks from project urls if not using subscriptions
- Fixed but where subscription and teams templates were still being included even if not enabled for a project
- Cleaned up progress bar demo
- Switched from
constin a few places
- Removed debug logging statements
May 7, 2020
Version 0.5.1 is a minor maintenance release with a few minor bug fixes and bits of cleanup:
- Upgraded Django to 3.0.5
- Fixed bug where certain input types were getting overridden in Django Forms (thanks Yaniv for reporting!)
- Fixed bug with Object Lifecycle and Charts demos not working on Team installations (thanks Greg for reporting!)
admin.pyfiles to use the
April 17, 2020
This is the biggest release to Pegasus since it’s launch. Read below for all the details.
Added the Stripe Subscriptions feature.
Documentation for subscriptions can be found here.
- Added a
CustomUserobjects, and a
SubscriptionModelMixinhelper class for accessing / checking subscription status on a model.
Pegasus.jsand made different modules available in front end code (see subscriptions upgrade page example usage).
Sass / CSS changes¶
- Added a few margin helper classes (e.g.
Small fixes and changes:¶
- Moved app-specific templates from inside the apps to global templates directory as recommended by Two Scoops of Django
- Remove redundant raw prefix on some
- Reduced some duplicate access to
teamobject when already available via the
- Made team permission template tags more consistent with rest of site (also allow access to superusers)
pegasus_settingscontext processor. All config is now handled at installation time instead of by settings variables.
- Catch Stripe card errors in the payments example
- Upgraded various
- Upgraded Bulma to 0.8.0