Skip to content

Commit

Permalink
bug fixes and cookiecutter
Browse files Browse the repository at this point in the history
  • Loading branch information
yairsimantov20 committed Jun 29, 2023
1 parent e8a0bf9 commit f39b6a9
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 33 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,9 @@ define deactivate_virtualenv
fi
endef

.SILENT: generate_config install lint run test clean
.SILENT: install lint run test clean

generate_config:
@if [[ ! -e .env ]]; then \
cp example.config.yaml config.yaml; \
fi

install: generate_config
install:
$(call deactivate_virtualenv) && \
$(call install_poetry) && \
poetry install --with dev
Expand Down

This file was deleted.

5 changes: 2 additions & 3 deletions port_ocean/core/handlers/port_app_config/models.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
from typing import Optional

from pydantic import BaseModel, Field

from port_ocean.clients.port.types import RequestOptions
from pydantic import BaseModel, Field


class EntityMapping(BaseModel):
identifier: str
title: str
title: str | None
blueprint: str
properties: dict[str, str] = Field(default_factory=dict)
relations: dict[str, str] = Field(default_factory=dict)
Expand Down
3 changes: 1 addition & 2 deletions port_ocean/core/integrations/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
)

from loguru import logger

from port_ocean.clients.port.types import UserAgentType
from port_ocean.context.event import (
event_context,
Expand Down Expand Up @@ -38,7 +37,7 @@ async def _sync_new_in_batches(

tasks = []

batch_size = self.context.config.batch_work_size or len(results)
batch_size = self.context.config.batch_work_size or len(results) or 1
for batch in [
results[i : i + batch_size] for i in range(0, len(results), batch_size)
]:
Expand Down

0 comments on commit f39b6a9

Please sign in to comment.