Class: Dependabot::Python::FileUpdater::PoetryFileUpdater

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Defined in:
lib/dependabot/python/file_updater/poetry_file_updater.rb,
lib/dependabot/python/file_updater/poetry_file_updater/pep621_updater.rb

Defined Under Namespace

Classes: Pep621Updater

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(dependencies:, dependency_files:, credentials:) ⇒ PoetryFileUpdater

Returns a new instance of PoetryFileUpdater.



42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# File 'lib/dependabot/python/file_updater/poetry_file_updater.rb', line 42

def initialize(dependencies:, dependency_files:, credentials:)
  @dependencies = dependencies
  @dependency_files = dependency_files
  @credentials = credentials
  @updated_dependency_files = T.let(nil, T.nilable(T::Array[Dependabot::DependencyFile]))
  @prepared_pyproject = T.let(nil, T.nilable(String))
  @pyproject = T.let(nil, T.nilable(Dependabot::DependencyFile))
  @lockfile = T.let(nil, T.nilable(Dependabot::DependencyFile))
  @updated_lockfile_content = T.let(nil, T.nilable(String))
  @language_version_manager = T.let(nil, T.nilable(LanguageVersionManager))
  @python_requirement_parser = T.let(nil, T.nilable(FileParser::PythonRequirementParser))
  @updated_pyproject_content = T.let(nil, T.nilable(String))
  @poetry_plugin_installer = T.let(nil, T.nilable(PoetryPluginInstaller))
  @poetry_lock = T.let(nil, T.nilable(Dependabot::DependencyFile))
end

Instance Attribute Details

#credentialsObject (readonly)

Returns the value of attribute credentials.



30
31
32
# File 'lib/dependabot/python/file_updater/poetry_file_updater.rb', line 30

def credentials
  @credentials
end

#dependenciesObject (readonly)

Returns the value of attribute dependencies.



33
34
35
# File 'lib/dependabot/python/file_updater/poetry_file_updater.rb', line 33

def dependencies
  @dependencies
end

#dependency_filesObject (readonly)

Returns the value of attribute dependency_files.



27
28
29
# File 'lib/dependabot/python/file_updater/poetry_file_updater.rb', line 27

def dependency_files
  @dependency_files
end

Instance Method Details

#updated_dependency_filesObject



59
60
61
# File 'lib/dependabot/python/file_updater/poetry_file_updater.rb', line 59

def updated_dependency_files
  @updated_dependency_files ||= fetch_updated_dependency_files
end