Skip to content

B2 SDK docs: Quick Start examples use invalid v3 encryption and upload arguments #584

Description

@ffumero2003

Description

doc/source/quick_start.rst contains examples that no longer match the public b2sdk.v3 interface. The examples use the nonexistent EncryptionSettings name, construct BasicSyncEncryptionSettingsProvider with only one mapping, pass id= to EncryptionKey, and pass file_infos= to Bucket.upload_local_file.

Steps to reproduce

from b2sdk.v3 import BasicSyncEncryptionSettingsProvider, EncryptionKey

EncryptionKey(secret=b'secret', id='example-key')
BasicSyncEncryptionSettingsProvider({'bucket': None})

Also compare the documented file_infos= argument with the current Bucket.upload_local_file(..., file_info=...) signature.

Expected behavior

Quick Start examples should use valid v3 names and signatures and should be usable as a reliable starting point.

Actual behavior

The examples raise NameError or TypeError, or show keywords that are not part of the v3 method signature.

Environment

  • Python version: Any supported version
  • b2sdk version: master at f3ab7b71
  • OS: Any

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions