CodeFurther Package Documentation v 0.1.0.dev15¶
This documentation is currently out of sync with the functionality in the CodeFurther package. In addition to the functionality described in this documentation, the following data sources have also been implemented:
On top of this, the following means of sharing have been implemented:
Many of these services require the presence of a cf_setting.py script that contains the following settings:
If this script file is not found, then the corresponding environment variable will be searched for.
The entire CodeFurther package is under development, so proceed
- CodeFurther Installation
- top40 - UK Top40 Charts
- Exploring the Top40 Demo Code
- Our example program
- Importing the PythonTop40 module
- Creating a Top40 instance
- Retrieving the Top40 albums
- The format of the returned data
- Accessing the information within each chart entry
- Printing extra information about the chart entry
- Formatting the output columns
- Accessing the change information
- Printing the change information
- Some finishing touches
- Top40 API
- lyrics - Search for song lyrics
- directions - Google maps routes
- CodeFurther utils
- CodeFurther errors
- Change Log for CodeFurther
The CodeFurther library is designed to be used in UK schools to provide students with access to data that hopefully has some relevance for them. The hope is that by gaining access to meaningful data, they will be inspired to CodeFurther.
The CodeFurther package is designed to be used in UK schools to provide programmatic access to data that describes the UK Top 40 singles and albums. The hope is that by providing simple interfaces to access information that students may have an interest in, they may be inspired to CodeFurther. This documentation will therefore most likely be aimed at teachers and education professionals, who may not have a deep knowledge of Python.
CodeFurther is currently designed to work with Python version 3. I have recently carried out some work to make it run on Python 2 too, but this does need to be more thoroughly tested that my current Nose tests allow. If you encounter any issues, or you’d like to submit a pull request, please contact me on BitBucket.
Modules in the Package¶
CodeFurther contains a number of modules that provide access to interesting data. Those modules are shown below:
|top40||Provides access to the UK Top 40 charts for singles and albums.|
|lyrics||Allows lyrics for a given artist and song title to be accessed within Python.|
|directions||Allows Google Maps route directions to be accessed from within Python.|
- a list of the current Top 40 UK singles using the singles <top40.Top40.singles> property of the ~top40.Top40 class.
- a list of the current Top 40 UK albums using the albums <top40.Top40.singles> property of the ~top40.Top40 class.
- the ability to retrieve the lyrics for a given artist
- the ability to find all of the songs for a given artist
- the ability to search for a specific artist
CodeFurther can be found on the Python Package Index PyPi here. It can be installed using pip, like so.
pip install codefurther
The documentation for CodeFurther can be found on the ReadTheDocs site.
To run the CodeFurther test suite, you should install the test and development requirements and then run nosetests.
$ pip install -r dev-requirements.txt $ nosetests tests
See Changes <changes>.