make passing an new Activity to create_table_snapshot easier
The python client currently does not have a method to save an Activity independently of an entity, and the create_table_snapshot method takes an activity id. This means there isn't a simple way of passing a new activity to this method. Either we should have an Activity creation helper and/or accept an Activity object in that method signature.
Current workaround e.g.:
activity = synapseclient.Activity(
activity = syn.restPOST('/activity', body=json.dumps(activity))
This is great! Another use case: sometimes we want to reuse pre-existing Activity objects, such as when running a script with different parameterizations and storing the result to a new entity. The last time I tried to borrow an Activity from entity #1 for use with an entity #2 I was about to store elsewhere it didn’t work. IIRC this was because Activity objects are somehow dependent on the entity they are associated with and aren’t meant to be reused. I would like to see an Activity model whose objects are independent and can be swapped around like any mutable property but there are skeptics. This and its linked issue go into more detail: