Skip to content

Commit

Permalink
Merge branch 'master' into feature/convex-decomp-app
Browse files Browse the repository at this point in the history
  • Loading branch information
Levi-Armstrong authored Jan 17, 2024
2 parents 0b4b6a9 + 4b4b9e1 commit 93af772
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 25 deletions.
45 changes: 24 additions & 21 deletions .github/workflows/conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ on:
jobs:
conda-win:
runs-on: windows-2019
defaults:
run:
shell: powershell
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -28,30 +31,31 @@ jobs:
- name: vcs import
run: >
vcs import --input "${{ github.workspace }}/workspace/src/tesseract/.github/workflows/windows_dependencies.repos" workspace/src/
- uses: conda-incubator/setup-miniconda@v2
- uses: conda-incubator/setup-miniconda@v3
with:
miniforge-variant: Mambaforge
channel-priority: true
channels: conda-forge
channel-priority: strict
environment-file: workspace/src/tesseract/.github/workflows/conda/environment.yml
use-mamba: true
- name: conda install
run: |
mamba activate test
mamba update --all -y
mamba install boa conda-smithy -y
auto-update-conda: true
activate-environment: tesseract-build
- name: build and test
run: |
mamba activate test
conda info
conda list
mkdir conda
xcopy /E workspace\src\tesseract\.github\workflows\conda conda
cd conda
New-Item -Name conda-forge.yml -ItemType File
conda smithy regenerate
mamba mambabuild -m .ci_support/win_64_.yaml .
conda mambabuild -m .ci_support/win_64_.yaml .
conda-linux:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -62,22 +66,21 @@ jobs:
- name: vcs import
run: >
vcs import --input "${{ github.workspace }}/workspace/src/tesseract/.github/workflows/windows_dependencies.repos" workspace/src/
- uses: conda-incubator/setup-miniconda@v2
- uses: conda-incubator/setup-miniconda@v3
with:
miniforge-variant: Mambaforge
channel-priority: true
channels: conda-forge
python-version: "3.10"
channel-priority: strict
environment-file: workspace/src/tesseract/.github/workflows/conda/environment.yml
use-mamba: true
- name: conda install
run: |
mamba update --all -y
mamba install boa conda-smithy -y
auto-update-conda: true
activate-environment: tesseract-build
- name: build and test
run: |
conda info
conda list
cp -r workspace/src/tesseract/.github/workflows/conda ./conda
cd conda
touch conda-forge.yml
conda smithy regenerate
mamba mambabuild -m .ci_support/linux_64_.yaml .
conda mambabuild -m .ci_support/linux_64_.yaml .
6 changes: 6 additions & 0 deletions .github/workflows/conda/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: tesseract-build
channels:
- conda-forge
dependencies:
- boa
- conda-smithy
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@ struct CollisionCheckConfig
/** @brief Used to configure the contact manager prior to a series of checks */
ContactManagerConfig contact_manager_config;

/** @brief ContactRequest that will be used for this check. Default test type: FIRST*/
/** @brief ContactRequest that will be used for this check. Default test type: ALL*/
ContactRequest contact_request;

/** @brief Specifies the type of collision check to be performed. Default: DISCRETE */
Expand Down
18 changes: 15 additions & 3 deletions tesseract_urdf/src/urdf_parser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,18 @@ tesseract_scene_graph::SceneGraph::UPtr parseURDFString(const std::string& urdf_
std::throw_with_nested(
std::runtime_error("URDF: Failed parsing attribute 'version' for robot '" + robot_name + "'!"));

if (urdf_version != 1)
std::throw_with_nested(
std::runtime_error("URDF: 'version' for robot '" + robot_name + "' is set to `" + std::to_string(urdf_version) +
"', this is not supported, please set it to 1.0. If you want to use a different tesseract "
"URDF parsing version use `tesseract_version=\"2\"`"));

int tesseract_urdf_version = 1;
auto tesseract_version_status = robot->QueryIntAttribute("tesseract_version", &tesseract_urdf_version);
if (tesseract_version_status != tinyxml2::XML_NO_ATTRIBUTE && tesseract_version_status != tinyxml2::XML_SUCCESS)
std::throw_with_nested(
std::runtime_error("URDF: Failed parsing attribute 'tesseract_version' for robot '" + robot_name + "'!"));

auto sg = std::make_unique<tesseract_scene_graph::SceneGraph>();
sg->setName(robot_name);

Expand All @@ -74,7 +86,7 @@ tesseract_scene_graph::SceneGraph::UPtr parseURDFString(const std::string& urdf_
std::unordered_map<std::string, tesseract_scene_graph::Material::Ptr> empty_material;
try
{
m = parseMaterial(material, empty_material, true, urdf_version);
m = parseMaterial(material, empty_material, true, tesseract_urdf_version);
}
catch (...)
{
Expand All @@ -91,7 +103,7 @@ tesseract_scene_graph::SceneGraph::UPtr parseURDFString(const std::string& urdf_
tesseract_scene_graph::Link::Ptr l = nullptr;
try
{
l = parseLink(link, locator, available_materials, urdf_version);
l = parseLink(link, locator, available_materials, tesseract_urdf_version);
}
catch (...)
{
Expand Down Expand Up @@ -119,7 +131,7 @@ tesseract_scene_graph::SceneGraph::UPtr parseURDFString(const std::string& urdf_
tesseract_scene_graph::Joint::Ptr j = nullptr;
try
{
j = parseJoint(joint, urdf_version);
j = parseJoint(joint, tesseract_urdf_version);
}
catch (...)
{
Expand Down

0 comments on commit 93af772

Please sign in to comment.