Skip to content

Commit

Permalink
fix sem_ver is string
Browse files Browse the repository at this point in the history
  • Loading branch information
FynnBe committed Mar 3, 2024
1 parent a10dbd8 commit 3b34d86
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions backoffice/remote_resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,10 +246,10 @@ def publish(self) -> PublishedVersion:
rdf = yaml.load(rdf_data)

sem_ver = rdf.get("version")
if sem_ver is not None and sem_ver in {
v.sem_ver for v in versions.published.values()
}:
raise RuntimeError(f"Trying to publish {sem_ver} again!")
if sem_ver is not None:
sem_ver = str(sem_ver)
if sem_ver in {v.sem_ver for v in versions.published.values()}:
raise RuntimeError(f"Trying to publish {sem_ver} again!")

ret = PublishedVersion(client=self.client, id=self.id, nr=next_publish_nr)

Expand Down

0 comments on commit 3b34d86

Please sign in to comment.