Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing ignition #2055

Merged
merged 11 commits into from
Aug 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docker/build.bash
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
if [ $# -eq 0 ]
then
echo "Usage: $0 <Gazebo meta-package name> <dockerfile>"
echo "Example: $0 ignition-blueprint ./Dockerfile.gz"
echo "Example: $0 gz-garden ./Dockerfile.gz"
exit 1
fi

Expand Down
82 changes: 0 additions & 82 deletions examples/worlds/deprecated_ignition.sdf

This file was deleted.

2 changes: 1 addition & 1 deletion include/gz/sim/System.hh
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ namespace gz
EventManager &_eventMgr) = 0;
};

/// \class ISystemConfigureParameters ISystem.hh ignition/gazebo/System.hh
/// \class ISystemConfigureParameters ISystem.hh gz/sim/System.hh
/// \brief Interface for a system that declares parameters.
///
/// ISystemConfigureParameters::ConfigureParameters is called after
Expand Down
2 changes: 1 addition & 1 deletion include/gz/sim/Util.hh
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ namespace gz
/// 2. "../shapes.sdf" - This is referencing a relative world file.
/// 3. "/home/user/shapes.sdf" - This is reference an absolute world
/// file.
/// 4. "https://fuel.ignitionrobotics.org/1.0/openrobotics/worlds/shapes.sdf"
/// 4. "https://fuel.gazebosim.org/1.0/openrobotics/worlds/shapes.sdf"
/// This is referencing a Fuel URI. This will download the world file.
/// \param[in] _fuelResourceCache Path to a Fuel resource cache, if
/// known.
Expand Down
4 changes: 2 additions & 2 deletions include/gz/sim/components/Model.hh
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ namespace serializers
{
// Skip serializing models with //pose/@relative_to attribute
// since deserialization will fail. This could be a nested model.
// see https://github.com/ignitionrobotics/ign-gazebo/issues/1071
// Once https://github.com/ignitionrobotics/sdformat/issues/820 is
// see https://github.com/gazebosim/gz-sim/issues/1071
// Once https://github.com/gazebosim/sdformat/issues/820 is
// resolved, there should be an API that returns sdf::Errors objects
// instead of printing console msgs so it would be easier to ignore
// specific errors in Deserialize.
Expand Down
24 changes: 2 additions & 22 deletions src/ServerConfig.cc
Original file line number Diff line number Diff line change
Expand Up @@ -546,17 +546,7 @@ const std::string &ServerConfig::RenderEngineServer() const
/////////////////////////////////////////////////
void ServerConfig::SetRenderEngineServer(const std::string &_engine)
{
// Deprecated: accept ignition-prefixed engines
std::string deprecatedPrefix{"ignition"};
auto engine = _engine;
auto pos = engine.find(deprecatedPrefix);
if (pos != std::string::npos)
{
engine.replace(pos, deprecatedPrefix.size(), "gz");
gzwarn << "Trying to load deprecated engine [" << _engine
<< "] for the server. Use [" << engine << "] instead." << std::endl;
}
this->dataPtr->renderEngineServer = engine;
this->dataPtr->renderEngineServer = _engine;
}

/////////////////////////////////////////////////
Expand Down Expand Up @@ -593,17 +583,7 @@ const std::string &ServerConfig::RenderEngineGui() const
/////////////////////////////////////////////////
void ServerConfig::SetRenderEngineGui(const std::string &_engine)
{
// Deprecated: accept ignition-prefixed engines
std::string deprecatedPrefix{"ignition"};
auto engine = _engine;
auto pos = engine.find(deprecatedPrefix);
if (pos != std::string::npos)
{
engine.replace(pos, deprecatedPrefix.size(), "gz");
gzwarn << "Trying to load deprecated engine [" << _engine
<< "] for the GUI. Use [" << engine << "] instead." << std::endl;
}
this->dataPtr->renderEngineGui = engine;
this->dataPtr->renderEngineGui = _engine;
}

/////////////////////////////////////////////////
Expand Down
2 changes: 1 addition & 1 deletion src/ServerPrivate.cc
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ struct LoggingPlugin
public: static std::string &LoggingPluginFileName()
{
static std::string recordPluginFileName =
std::string("ignition-gazebo") +
std::string("gz-sim") +
GZ_SIM_MAJOR_VERSION_STR + "-log-system";
return recordPluginFileName;
}
Expand Down
4 changes: 3 additions & 1 deletion src/SystemLoader.cc
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ class gz::sim::SystemLoaderPrivate
public: bool InstantiateSystemPlugin(const sdf::Plugin &_sdfPlugin,
gz::plugin::PluginPtr &_gzPlugin)
{
// Deprecated: accept ignition-gazebo-prefixed systems
// Deprecated: accept ignition-gazebo-prefixed systems. Remove this on
// gz-sim9
std::string deprecatedPrefix{"ignition-gazebo"};
auto filename = _sdfPlugin.Filename();
auto pos = filename.find(deprecatedPrefix);
Expand Down Expand Up @@ -124,6 +125,7 @@ class gz::sim::SystemLoaderPrivate
std::string pluginToInstantiate = _sdfPlugin.Name().empty() ?
pluginName : _sdfPlugin.Name();

// Deprecated: accept ignition plugins. Remove this on gz-sim9
std::string deprecatedPluginNamePrefix{"ignition::gazebo"};
pos = pluginToInstantiate.find(deprecatedPluginNamePrefix);
if (pos != std::string::npos)
Expand Down
4 changes: 2 additions & 2 deletions src/Util_TEST.cc
Original file line number Diff line number Diff line change
Expand Up @@ -974,11 +974,11 @@ TEST_F(UtilTest, ResolveSdfWorldFile)

// URI to a Fuel world.
std::string fuelUri =
"https://fuel.ignitionrobotics.org/1.0/openrobotics/worlds/test world";
"https://fuel.gazebosim.org/1.0/openrobotics/worlds/test world";

// The expect path for the local Fuel world.
std::string expectedPath = common::joinPaths(
config.CacheLocation(), "fuel.ignitionrobotics.org",
config.CacheLocation(), "fuel.gazebosim.org",
"openrobotics", "worlds", "test world");

// Get the Fuel world.
Expand Down
4 changes: 2 additions & 2 deletions src/gui/plugins/banana_for_scale/BananaForScale.cc
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ namespace gz::sim
}

const char kBanana[] =
"https://fuel.ignitionrobotics.org/1.0/mjcarroll/models/banana for scale";
"https://fuel.gazebosim.org/1.0/mjcarroll/models/banana for scale";

const char kBigBanana[] =
"https://fuel.ignitionrobotics.org/1.0/mjcarroll/models/big banana for scale";
"https://fuel.gazebosim.org/1.0/mjcarroll/models/big banana for scale";

using namespace gz;
using namespace sim;
Expand Down
4 changes: 2 additions & 2 deletions src/gui/plugins/component_inspector/ComponentInspector.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1257,8 +1257,8 @@ void ComponentInspector::QuerySystems()

// Remove common prefixes and suffixes
auto humanReadable = plugin.filename();
removePrefix("ignition-gazebo-", humanReadable);
removePrefix("ignition-gazebo" +
removePrefix("gz-sim-", humanReadable);
removePrefix("gz-sim" +
std::string(GZ_SIM_MAJOR_VERSION_STR) + "-", humanReadable);
removeSuffix("-system", humanReadable);
removeSuffix("system", humanReadable);
Expand Down
21 changes: 0 additions & 21 deletions src/gui/plugins/resource_spawner/ResourceSpawner.cc
Original file line number Diff line number Diff line change
Expand Up @@ -552,27 +552,6 @@ void ResourceSpawner::LoadConfig(const tinyxml2::XMLElement *)
}

auto servers = this->dataPtr->fuelClient->Config().Servers();
// Since the ign->gz rename, `servers` here returns two items for the
// canonical Fuel server: fuel.ignitionrobotics.org and fuel.gazebosim.org.
// For the purposes of the ResourceSpawner, these will be treated as the same
// and we will remove the ignitionrobotics server here.
auto urlIs = [](const std::string &_url)
{
return [_url](const fuel_tools::ServerConfig &_server)
{ return _server.Url().Str() == _url; };
};

auto ignIt = std::find_if(servers.begin(), servers.end(),
urlIs("https://fuel.ignitionrobotics.org"));
if (ignIt != servers.end())
{
auto gzsimIt = std::find_if(servers.begin(), servers.end(),
urlIs("https://fuel.gazebosim.org"));
if (gzsimIt != servers.end())
{
servers.erase(ignIt);
}
}

gzmsg << "Please wait... Loading models from Fuel.\n";

Expand Down
12 changes: 1 addition & 11 deletions src/rendering/RenderUtil.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2797,17 +2797,7 @@ void RenderUtil::ShowGrid()
/////////////////////////////////////////////////
void RenderUtil::SetEngineName(const std::string &_name)
{
// Deprecated: accept ignition-prefixed engines
std::string deprecatedPrefix{"ignition"};
auto name = _name;
auto pos = name.find(deprecatedPrefix);
if (pos != std::string::npos)
{
name.replace(pos, deprecatedPrefix.size(), "gz");
gzwarn << "Trying to load deprecated engine [" << _name
<< "] for the server. Use [" << name << "] instead." << std::endl;
}
this->dataPtr->engineName = name;
this->dataPtr->engineName = _name;
}

/////////////////////////////////////////////////
Expand Down
11 changes: 1 addition & 10 deletions src/systems/hydrodynamics/Hydrodynamics.cc
Original file line number Diff line number Diff line change
Expand Up @@ -293,16 +293,7 @@ void Hydrodynamics::Configure(
gz::sim::EventManager &/*_eventMgr*/
)
{
if (_sdf->HasElement("waterDensity"))
{
gzwarn <<
"<waterDensity> parameter is deprecated and will be removed Ignition G.\n"
<< "\tPlease update your SDF to use <water_density> instead.";
}

this->dataPtr->waterDensity = SdfParamDouble(_sdf, "waterDensity",
SdfParamDouble(_sdf, "water_density", 998)
);
this->dataPtr->waterDensity = SdfParamDouble(_sdf, "water_density", 998);
// Load stability derivatives
// Use SNAME 1950 convention to load the coeffecients.
const auto snameConventionVel = "UVWPQR";
Expand Down
3 changes: 1 addition & 2 deletions src/systems/log/LogPlayback.cc
Original file line number Diff line number Diff line change
Expand Up @@ -510,8 +510,7 @@ void LogPlayback::Update(const UpdateInfo &_info, EntityComponentManager &_ecm)
{
auto msgType = iter->Type();

// Support ignition.msgs for backwards compatibility, don't remove on tock
// so users can use logs across versions
// Support ignition.msgs for backwards compatibility. Remove on gz-sim9
std::string deprecatedPrefix{"ignition.msgs"};
auto pos = msgType.find(deprecatedPrefix);
if (pos != std::string::npos)
Expand Down
10 changes: 0 additions & 10 deletions src/systems/physics/Physics.cc
Original file line number Diff line number Diff line change
Expand Up @@ -776,16 +776,6 @@ void Physics::Configure(const Entity &_entity,
pluginLib = "gz-physics-dartsim-plugin";
}

// Deprecated: accept ignition-prefixed engines
std::string deprecatedPrefix{"ignition"};
auto pos = pluginLib.find(deprecatedPrefix);
if (pos != std::string::npos)
{
auto msg = "Trying to load deprecated plugin [" + pluginLib + "]. Use [";
pluginLib.replace(pos, deprecatedPrefix.size(), "gz");
gzwarn << msg << pluginLib << "] instead." << std::endl;
}

// Update component
if (!engineComp)
{
Expand Down
4 changes: 2 additions & 2 deletions src/systems/triggered_publisher/TriggeredPublisher.hh
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,8 @@ namespace systems
/// * Attributes:
/// * `name`: Service name (eg. `/world/triggered_publisher/set_pose`)
/// * `timeout`: Service timeout
/// * `reqType`: Service request message type (eg. ignition.msgs.Pose)
/// * `repType`: Service response message type (eg. ignition.msgs.Empty)
/// * `reqType`: Service request message type (eg. gz.msgs.Pose)
/// * `repType`: Service response message type (eg. gz.msgs.Empty)
/// * `reqMsg`: String used to construct the service protobuf message.
///
/// Examples:
Expand Down
4 changes: 2 additions & 2 deletions test/integration/battery_plugin.cc
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ TEST_F(BatteryPluginTest,
// the LinearBatteryPlugin is not zero when created. If
// components::BatterySoC is zero on start, then the Physics plugin
// can disable a joint. This in turn can prevent the joint from
// rotating. See https://github.com/ignitionrobotics/ign-gazebo/issues/55
// rotating. See https://github.com/gazebosim/gz-sim/issues/55
EXPECT_GT(batComp->Data(), 0);
EXPECT_GT(batComp2->Data(), 0);
};
Expand Down Expand Up @@ -333,7 +333,7 @@ TEST_F(BatteryPluginTest,

/////////////////////////////////////////////////
// Battery with power draining topics
// See https://github.com/ignitionrobotics/ign-gazebo/issues/1175
// See https://github.com/gazebosim/gz-sim/issues/1175
TEST_F(BatteryPluginTest, GZ_UTILS_TEST_DISABLED_ON_WIN32(PowerDrainTopic))
{
const auto sdfPath = common::joinPaths(std::string(PROJECT_SOURCE_PATH),
Expand Down
Loading