Skip to content

Commit

Permalink
fix: Upload resource error in 4.0.x
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongjiajie committed Apr 3, 2023
1 parent 0c40796 commit aec75a7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/pydolphinscheduler/core/resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,6 @@ def create_or_update_resource(self):
return gateway.create_or_update_resource(
self.user_name,
self.name,
self.description,
self.content,
)
8 changes: 6 additions & 2 deletions src/pydolphinscheduler/java_gateway.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,13 @@ def get_resources_file_info(self, program_type: str, main_package: str):
"""Get resources file info through java gateway."""
return self.gateway.entry_point.getResourcesFileInfo(program_type, main_package)

def create_or_update_resource(self, user_name: str, name: str, content: str):
def create_or_update_resource(
self, user_name: str, name: str, description: str, content: str
):
"""Create or update resource through java gateway."""
return self.gateway.entry_point.createOrUpdateResource(user_name, name, content)
return self.gateway.entry_point.createOrUpdateResource(
user_name, name, description, content
)

def query_resources_file_info(self, user_name: str, name: str):
"""Get resources file info through java gateway."""
Expand Down

0 comments on commit aec75a7

Please sign in to comment.