Skip to content

Commit

Permalink
Remove all debug logging.
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Jackson <[email protected]>
  • Loading branch information
imikejackson committed Apr 17, 2024
1 parent 173e272 commit fcce111
Showing 1 changed file with 6 additions and 36 deletions.
42 changes: 6 additions & 36 deletions wrapping/python/docs/generate_sphinx_docs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ namespace

std::map<nx::core::Uuid, std::string> s_ParameterMap;

const std::string k_WebServerAddress = "http://www.dream3d.io/nx_reference_manual";
const std::string k_WebServerAddress = "https://www.dream3d.io/nx_reference_manual";
const std::string k_WebServerFilterFolder = "html";
} // namespace

Expand Down Expand Up @@ -671,9 +671,6 @@ void GenerateMarkdownFilterParameterTable()
void GeneratePythonRstFiles()
{
auto* filterListPtr = Application::Instance()->getFilterList();
std::ofstream logFile("/tmp/parameter_key_updates.log", std::ios_base::trunc);

std::set<std::string> thingsWithGeomInName;

// Loop over each plugin and create a .rst file
const auto pluginListPtr = Application::Instance()->getPluginList();
Expand Down Expand Up @@ -768,15 +765,15 @@ void GeneratePythonRstFiles()
for(const auto& parameter : parameters)
{
auto const& paramValue = parameter.second;
// if(paramValue->helpText().empty())
// {
// std::cout << filter->name() << "::" << paramValue->name() << " HELP Text is empty\n";
// }
if(paramValue->helpText().empty())
{
std::cout << filter->name() << "::" << paramValue->name() << " HELP Text is empty\n";
}
for(const auto& letter : paramValue->name())
{
if(::isupper(letter) != 0)
{
logFile << filter->name() << "::" << paramValue->name() << " HAS CAPS. Should be lower snake case\n";
std::cout << filter->name() << "::" << paramValue->name() << " HAS CAPS. Should be lower snake case\n";
break;
}
}
Expand All @@ -796,28 +793,6 @@ void GeneratePythonRstFiles()
{
auto const& anyParameter = parameterPair.second;
rstStream << ", ";
std::string pType = s_ParameterMap[anyParameter->uuid()];
if(!nx::core::StringUtilities::ends_with(parameterPair.first, "_path") &&
(pType == "simplnx.ArraySelectionParameter" || pType == "simplnx.ArrayCreationParameter" || pType == "simplnx.AttributeMatrixSelectionParameter" ||
pType == "simplnx.DataGroupCreationParameter" || pType == "simplnx.DataGroupSelectionParameter" || pType == "simplnx.DataPathSelectionParameter" ||
pType == "simplnx.GeometrySelectionParameter" || pType == "simplnx.NeighborListSelectionParameter" || pType == "simplnx.DataGroupCreationParameter"))
{
logFile << filterClassName << " " << parameterPair.first << " " << pType << std::endl;
}

if(pType == "simplnx.MultiArraySelectionParameter" && !nx::core::StringUtilities::ends_with(parameterPair.first, "s"))
{
logFile << filterClassName << " " << parameterPair.first << " " << pType << std::endl;
}

if(pType == "simplnx.DataObjectNameParameter" && !nx::core::StringUtilities::ends_with(parameterPair.first, "_name"))
{
logFile << filterClassName << " " << parameterPair.first << " " << pType << std::endl;
}
if(nx::core::StringUtilities::contains(parameterPair.first, "data_array"))
{
thingsWithGeomInName.insert(parameterPair.first);
}

rstStream << parameterPair.first;
memberStream << " :param nx." << nx::core::StringUtilities::replace(s_ParameterMap[anyParameter->uuid()], "simplnx.", "") << " " << anyParameter->name() << ": "
Expand All @@ -832,11 +807,6 @@ void GeneratePythonRstFiles()
rstStream << '\n';
}
}

for(const auto& name : thingsWithGeomInName)
{
logFile << name << "\n";
}
}

/**
Expand Down

0 comments on commit fcce111

Please sign in to comment.