Skip to content

v2.0.0

Compare
Choose a tag to compare
@github-actions github-actions released this 04 Oct 16:50
· 38 commits to refs/heads/main since this release

Breaking Changes

As of #96, a function ID is no longer sufficient to connect to a Cape function. Whenever one intends to use a Cape function, they must pass a fully-specified pycape.FunctionRef (which now requires both function ID and function token). The idiomatic way of doing this is to load the FunctionRef from JSON (see examples).

Previously, one could supply function ID strings instead of the full FunctionRef. For example, the following two code snippets were equivalent:

# Method 1
cape.connect("sa15lcf12td45s1")
cape.close()

# Method 2
fref = pycape.FunctionRef("sa15lcf12td45s1")
cape.connect(fref)
cape.close()

The breaking change is that Method 1 is now forbidden and will yield a TypeError if attempted.

What's Changed