What methods and tools can we use to make it easier to write less buggy Python software? At this inaugural event we’ll be exploring this question via three short talks. Each will be ~10 minutes, leaving half an hour for discussion/questions.
Blackboard Collaborate event (participants can join 15 mins before the start of the session).
Google JamBoard for Q&A: note down questions/comments (using JamBoard Sticky Notes) before/during the event.
Joe Heffer, Research Data Engineer, IT Services
What on earth is that object? Make your Python code more readable, for yourself and your collaborators, reduce risk of incorrect inputs and increase your IDE productivity by annotating your functions with type hints.
David Jones, Research Software Engineer, RSE team
You can test your Python code with pytest, one of the leading systems for testing Python code. Here I will gently introduce you to pytest with practical examples. As pytest themselves put it pytest “helps you write better programs”.
Will Furnass, Research Software Engineer, RSE team
Everyone who writes code needs to consider if/when/how to encapsulate code as functions.
But what makes for a good function that you can test/validate? One strategy is to try to write a proportion of your functions so they don’t have ‘side effects’,
where a side effect is something like reading/writing a file or reading/writing data over a network.
By creating functions that only return useful values and don’t perform side effects functions can be much easier to test.
Here we discuss why, when and when not to write functions without side effects.
This talk should be of interest to those who write Python code and code in other languages.
For queries relating to collaborating with the RSE team on projects: firstname.lastname@example.org
Join our mailing list so as to be notified when we advertise talks and workshops by subscribing to this Google Group.