We can't find the internet
Attempting to reconnect
Something went wrong!
Hang in there while we get back on track
phoenix changelog
Hey there, fabulous developers! 🎉 We've got some shiny new updates that are sure to make your coding life a little bit more delightful. Let's dive right in and see what's new in the world of Phoenix!
New Features & Improvements
-
Phoenix Debugging Magic 🕵️♂️: Introducing the brand new
Phoenix.Debug
module! This nifty addition is here to sprinkle some debugging pixie dust on your Phoenix applications. Now you can easily list all connectedPhoenix.Socket
transport processes, retrieve channels linked to specific sockets, and verify if a process is aPhoenix.Socket
orPhoenix.Channel
. With thorough documentation and tests, you'll have all the tools you need for top-notch runtime introspection and debugging. Plus, we've added process labels and channel info retrieval methods to make your real-time features a breeze to debug. -
Core Components Upgrade 🛠️: We've given the
core_components.ex
file a little makeover! By adding "download" to the:rest
attributes, your components are now more versatile than ever. Whether you're dealing with file downloads or just want a bit more flexibility, this update has got your back. -
Shopping Cart Wisdom 🛒: In our ongoing quest to make your data modeling smoother, we've refined the cross-context boundaries guide. User input for price is now a thing of the past — we're discarding it to boost data integrity and keep those pesky errors at bay. The
quantity
attribute remains, ensuring all inputs are within a sensible range. Plus, we've tightened up the relationships betweenShoppingCart
andCatalog
schemas, making your shopping cart context APIs more robust than ever.
That's all for now, folks! Keep on coding, and may your bugs be few and your features many. 🚀✨
Included Commits
The commit titled "discard price user input in cross-context boundaries guide" focuses on refining the data modeling for a shopping cart system by removing user input for the price attribute. Specifically, it modifies the changeset function in the cross_context_boundaries.md
guide to eliminate the price_when_carted
field from the list of cast attributes and required validations. This change ensures that any price provided by user input is disregarded, thereby enhancing data integrity and reducing potential errors associated with user-defined pricing.
In addition to this adjustment, the commit retains the quantity
attribute, which is now the only required field for validation, ensuring that any quantity input falls within the range of 0 to 100. The modifications also include establishing relationships between the ShoppingCart
and Catalog
schemas, reinforcing the structure of cross-context data dependencies. Overall, these changes aim to streamline the integration of new data structures and enhance the functionality of the shopping cart context APIs within the web application.
Files changed
- guides/data_modelling/cross_context_boundaries.md
The commit updates the core_components.ex
file within the installer/templates/phx_web/components/
directory. It modifies the attributes of a component by adding "download" to the list of included attributes in the :rest
attribute, while also making a minor adjustment to the existing attributes.
Specifically, the line defining the :rest
attribute has been changed to include the new "download" option, enhancing the component's functionality. This change allows for more flexibility in how components can be used, particularly in scenarios where file downloads are necessary. Overall, the commit improves the usability of the core components in the Phoenix web framework.
Files changed
- installer/templates/phx_web/components/core_components.ex
The commit titled "Phoenix.Debug" introduces a new module, Phoenix.Debug
, designed to enhance runtime introspection and debugging capabilities for Phoenix applications. This module provides several utilities, such as listing all currently connected Phoenix.Socket
transport processes, retrieving channels associated with a specific socket, and checking if a given process is a Phoenix.Socket
or Phoenix.Channel
. The commit includes extensive documentation and tests to ensure the functionality works as intended, and it modifies existing files within the Phoenix framework to integrate these new debugging features.
Additionally, the commit involves changes to the Phoenix.Socket
and Phoenix.Channel.Server
modules, including the addition of process labels and methods to retrieve channel information. The updates are aimed at improving the debugging experience for developers working with Phoenix applications, particularly in scenarios involving real-time features like channels and live views. The tests included in this commit validate the new functions, ensuring they perform correctly in various scenarios, thereby enhancing the reliability of the debugging tools provided.
Files changed
- lib/phoenix/channel/server.ex
- lib/phoenix/debug.ex
- lib/phoenix/socket.ex
- test/phoenix/debug_test.exs