Skip to content

Releases: neohaskell/NeoHaskell

v0.5.0: HTTP, TOML, Nested Actions Now Executed and Major Refactoring

16 Sep 15:25
deb9780
Compare
Choose a tag to compare

🚀 New Features and Improvements

🛠️ Fixed Execution of Nested Actions

  • Issue Addressed: Nested actions were not being executed, leading to incomplete workflows and unexpected behavior.
  • Solution: Refactored the action processing system to correctly handle and execute nested actions.
  • Impact: Ensures that all intended actions are performed, providing more reliable and predictable application behavior.

🌐 Introduced HTTP Client Support

  • Capability: Added HTTP client functionalities using the http-conduit library.
  • Modules Added:
    • core/http/Http.hs
    • core/http/Http/Client.hs
  • Features:
    • Perform HTTP GET requests with JSON parsing.
    • Seamless integration of HTTP requests into NeoHaskell applications.
  • Note: Currently supports only GET requests.

📄 Transitioned from YAML to TOML for Configuration

  • Change: Replaced YAML configuration support with TOML.
  • Reason: TOML offers a simpler syntax and is better suited for configuration needs.
  • Action Required: Users must migrate their YAML configuration files to TOML format.
  • Modules Affected:
    • Removed: core/yaml/Yaml.hs
    • Added: core/toml/Toml.hs (using the toml-parser library)

⚙️ Refactored Core Modules

  • Standardization and Cleanup:
    • Removed custom implementations and redundant GHC extensions.
    • Cleaned up imports and exports in core modules for clarity and maintainability.
  • IO Module Enhancements (core/core/IO.hs):
    • Added map and try functions for improved error handling and functional composition.
  • Result Module Enhancements (core/core/Result.hs):
    • Introduced fromEither function for better interoperability with Haskell's Either type.

🚀 Improved Service Layer

  • Action Processing (core/service/Action.hs):
    • Rewrote action processing logic to correctly handle nested actions.
    • Adjusted the Action type and related functions to support new data structures.
  • Event Handling (core/service/Service/EventWorker.hs):
    • Enhanced event worker logic to accurately process events derived from actions.
    • Ensured proper propagation of events throughout the system.
  • Runtime State Management (core/service/Service/RuntimeState.hs):
    • Refactored runtime state handling to use standard data types.
    • Simplified registration of default action handlers and improved extensibility.

🧹 Removed large-anon Library and Anonymous Records

  • Change: Eliminated the large-anon library and the use of anonymous records.
  • Reason: To simplify the codebase, reduce complexity, and improve performance.
  • Changes Made:
    • Replaced anonymous records with standard Haskell data types using data declarations.
    • Removed GHC extensions: OverloadedRecordUpdate, RebindableSyntax, and unnecessary OverloadedRecordDot.
    • Updated all modules to use conventional records, enhancing compatibility and maintainability.
  • Note: This feature might be reintroduced in the future.

📝 Miscellaneous Changes

  • Updated Cabal Files:
    • cli/nhcli.cabal and core/nhcore.cabal updated.
    • Removed unused dependencies and GHC extensions.
    • Added new dependencies: http-conduit, toml-parser.
  • Console and Logging Enhancements:
    • Improved logging messages for better debugging and visibility.
    • Standardized log formats and included more contextual information.
  • Code Cleanup:
    • Removed deprecated code and modules (e.g., core/yaml/Yaml.hs, cli/src/Neo/Transpile.hs).
    • Ensured all modules are updated to use new data type definitions.
  • Removed Modules:
    • Deleted content of core/core/Record.hs as it's no longer necessary.
    • Removed dependencies on external libraries in core/service/Html.hs, provided placeholders instead.

⚠️ Breaking Changes

  • Data Types:
    • Replaced anonymous records with standard data types.
    • Affects the structure of State, Event, Action, and other core components.
  • GHC Extensions:
    • Removed extensions that were previously required for anonymous records.
  • Configuration Files:
    • Users need to migrate their configuration files from YAML to TOML format.
  • Module Imports:
    • Updated module imports and exports.
    • User code may require updates to accommodate these changes.

v0.4.0 - Enhanced CLI Parsing, Bug Fixes, and Architectural Improvements

01 Sep 17:32
714a27c
Compare
Choose a tag to compare

New Features

  1. Enhanced CLI Argument Parsing

    • Introduced a new Command module with improved functionality for parsing CLI arguments.
    • Added support for Path type arguments in CLI parsing.
    • Integrated CLI argument parsing with the action system for seamless command handling.
  2. Improved Text Formatting

    • Added support for text interpolation using the fmt quasi-quoter, allowing for more readable string formatting.

Bug Fixes

  1. Terminal Rendering Issue Resolved

    • Fixed a critical bug where the terminal was left in an unusable state after program exit.
    • Implemented proper cleanup using Vty.shutdown to ensure the terminal returns to a normal state.
  2. Exception Handling in Worker Threads

    • Resolved an issue where worker threads couldn't stop gracefully on exceptions.
    • Implemented a coordinated shutdown mechanism across all threads using a shouldExit flag.

Improvements and Refactoring

  1. Service Architecture Overhaul

    • Refactored the monolithic Service module into smaller, focused modules for improved maintainability:
      • Service.Core: Core types and interfaces
      • Service.ActionWorker: Action processing
      • Service.EventWorker: Event handling and model updates
      • Service.RenderWorker: View rendering
      • Service.RuntimeState: Shared runtime state management
  2. Enhanced Error Handling

    • Introduced a new ActionResult type in the Action module for more robust error management.
    • Improved logging and error reporting throughout service components.
  3. Core Module Updates

    • Added new utility functions to Array, Basics, and IO modules, expanding the toolkit for developers.

These updates significantly improve the stability, functionality, and developer experience of the NeoHaskell CLI. Users should experience better performance, more reliable CLI interactions, and improved error handling.

v0.3.0 - Triggers and renaming

04 Aug 17:31
650610e
Compare
Choose a tag to compare
  1. Major Architecture Refactoring:

    • Renamed "Command" to "Action" throughout the codebase for clarity.
    • Replaced "Platform" with "Service" as the core runtime concept.
    • Introduced a new "Trigger" system for handling background processes and events.
  2. Enhanced Time-based Functionality:

    • Added a new Time module with triggerEveryMilliseconds function.
    • Implemented support for creating time-based triggers that generate events at specified intervals.
  3. Improved Project Structure:

    • Reorganized core modules into more logical groupings (e.g., 'system', 'service').
    • Moved file-related operations to a dedicated 'File' module in the 'system' directory.
  4. Updated CLI Implementation:

    • Refactored the main Neo module to use the new Service and Action paradigms.
    • Added support for a simple counter demonstration using the new time-based trigger system.
  5. Development Environment Improvements:

    • Switched from ghcup to DevEnv for development environment setup.
    • Updated README with new setup instructions for contributors.
  6. Artifact System Updates:

    • Expanded support for various artifact types, including React components and SVG images.
    • Improved handling and rendering of different artifact types.
  7. Dependencies and Libraries:

    • Added 'nanotime' as a new dependency for precise time measurements.
    • Updated cabal file to reflect new module structure and dependencies.
  8. Documentation:

    • Removed placeholder text from README, replacing it with actual project information and setup instructions.
    • Added inline documentation for new concepts like Triggers and Actions.

v0.2.0 - Basic CLI Scaffolding

27 Jul 10:33
b410aa7
Compare
Choose a tag to compare

This release lays the foundation for building CLI applications in NeoHaskell using an Elm-inspired architecture. It introduces a basic scaffolding for CLI apps and significantly expands the core library functionality.

Key Features

  1. CLI Application Architecture:

    • Introduced a Platform module that provides an Elm-like architecture for CLI apps
    • Added Command and Html modules to support this architecture
    • Implemented a main event loop and rendering system using the brick library
  2. Enhanced Core Library:

    • Added Channel, Var, and ConcurrentVar modules for improved concurrency support
    • Introduced AsyncIO for asynchronous operations
    • Expanded Array module with new functions like flatMap and forEach
    • Added Version module with parsing and quasiquoting capabilities
  3. Improved Type System:

    • Introduced Unknown type for dynamic typing scenarios
    • Added Record module for working with extensible records
  4. New Modules:

    • Json and Yaml modules for data serialization and deserialization
    • OptionsParser module for CLI argument parsing
    • Console module with debugging capabilities
  5. Trait System Enhancements:

    • Reorganized and expanded trait modules (e.g., Appendable, Applicable, Combinable)
    • Introduced ToText trait for consistent string conversion
  6. Project Structure:

    • Restructured the project layout for better organization
    • Added a basic project configuration file (project.yaml)
  7. Development Environment:

    • Updated devenv.nix for an improved development setup
    • Added CodeRabbit configuration for code review automation

Breaking Changes

  • Significant changes to the core library structure and module names
  • Altered behavior of some existing functions to align with the new architecture

Notes

This release focuses on establishing the foundational architecture for NeoHaskell CLI applications. While it introduces many new features, it's important to note that the API is still in flux and may undergo further changes in future releases.

v0.1.0 - Barebones Core Library

26 May 22:01
775d79f
Compare
Choose a tag to compare

Barebones Core Library

This version includes a fork of nri-prelude that has been modified to follow the NeoHaskell goals.

What's Changed

New Contributors

Full Changelog: https://github.com/neohaskell/NeoHaskell/commits/v0.1.0