Python's self vs instance
<p>What is the difference between the self and instance keywords in Python 3?</p>

<p>I see code like,</p>

<pre><code>def update(self, instance, validated_data):
    """
    Update and return an existing `Snippet` instance, given the validated data.
    """
    instance.title = validated_data.get('title', instance.title)
    instance.code = validated_data.get('code', instance.code)
    instance.linenos = validated_data.get('linenos', instance.linenos)
    instance.language = validated_data.get('language', instance.language)
    instance.style = validated_data.get('style', instance.style)
    instance.save()
    return instance
</code></pre>

<p>The snippet is a bit short but <code>instance</code> is not a keyword (neither <code>self</code>, that is just convention).</p>

<p>It is an argument to another instance of another (maybe same) class.</p>

python django