πŸ“… 2023-05-02 β€” Session: Developed Python script for Jupyter notebook conversion

πŸ•’ 18:00–19:00
🏷️ Labels: Python, Jupyter, Code Conversion, Regex, File Handling
πŸ“‚ Project: Dev
⭐ Priority: MEDIUM

Session Goal

The session aimed to develop a Python script capable of converting a Python file into a Jupyter notebook format by ensuring proper formatting and handling of cell indicators.

Key Activities

  • Introduced SQL basics including database creation and management.
  • Modified Python code to ensure an empty line precedes each # %% cell indicator for better readability.
  • Implemented a regex pattern to handle newline issues in Python scripts.
  • Developed a Python script to convert a Python file into a Jupyter notebook, ensuring proper formatting and saving the results.
  • Debugged and improved regex patterns for text processing and newline handling.

Achievements

  • Successfully created a Python script that modifies a given file, adds necessary formatting, and converts it into a Jupyter notebook.
  • Ensured that the script handles both markdown and code cells appropriately.

Pending Tasks

  • Verify the script’s functionality with various Python files to ensure robustness and handle edge cases.