Skip to content

Commit

Permalink
Merge pull request #16485 from Ultimaker/CURA-10619_infill_fix
Browse files Browse the repository at this point in the history
Send over plugin name and version
  • Loading branch information
rburema authored Aug 16, 2023
2 parents 0667230 + 8cc54b0 commit 5ac4303
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ def validate(self):
def requirements(self):
self.requires("boost/1.81.0")
self.requires("pyarcus/(latest)@ultimaker/cura_10475")
self.requires("curaengine/(latest)@ultimaker/cura_10475")
self.requires("curaengine/(latest)@ultimaker/cura_10619")
self.requires("pysavitar/5.2.2")
self.requires("pynest2d/5.2.2")
self.requires("uranium/(latest)@ultimaker/cura_10475")
Expand Down
8 changes: 6 additions & 2 deletions cura/BackendPlugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,13 @@
from UM.Logger import Logger
from UM.Message import Message
from UM.Settings.AdditionalSettingDefinitionAppender import AdditionalSettingDefinitionsAppender
from UM.PluginObject import PluginObject
from UM.i18n import i18nCatalog


class BackendPlugin(AdditionalSettingDefinitionsAppender):
class BackendPlugin(AdditionalSettingDefinitionsAppender, PluginObject):
catalog = i18nCatalog("cura")

def __init__(self) -> None:
super().__init__()
self.__port: int = 0
Expand Down Expand Up @@ -42,7 +46,7 @@ def _validatePluginCommand(self) -> list[str]:
if not self._plugin_command or "--port" in self._plugin_command:
return self._plugin_command or []

return self._plugin_command + ["--port", str(self.__port)]
return self._plugin_command + ["--address", self.getAddress(), "--port", str(self.__port)]

def start(self) -> bool:
"""
Expand Down
6 changes: 4 additions & 2 deletions plugins/CuraEngineBackend/Cura.proto
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ enum SlotID {
message EnginePlugin
{
SlotID id = 1;
optional string address = 2;
optional uint32 port = 3;
string address = 2;
uint32 port = 3;
string plugin_name = 4;
string plugin_version = 5;
}

message Slice
Expand Down
2 changes: 2 additions & 0 deletions plugins/CuraEngineBackend/StartSliceJob.py
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,8 @@ def run(self) -> None:
plugin_message.id = slot
plugin_message.address = plugin.getAddress()
plugin_message.port = plugin.getPort()
plugin_message.plugin_name = plugin.getPluginId()
plugin_message.plugin_version = plugin.getVersion()

for group in filtered_object_groups:
group_message = self._slice_message.addRepeatedMessage("object_lists")
Expand Down

0 comments on commit 5ac4303

Please sign in to comment.