Skip to content

Commit

Permalink
Update supported ns-3 version to ns-3.41 (#157)
Browse files Browse the repository at this point in the history
* Patch code for ns-3.41 compatibility
* Update CI to replicate the one of ns-3.41
  • Loading branch information
non-det-alle authored Mar 20, 2024
1 parent 6babcbe commit 792728d
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 11 deletions.
3 changes: 1 addition & 2 deletions .github/actions/install-linting/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ runs:
run: >
apt update && DEBIAN_FRONTEND=noninteractive apt install -y
clang cmake
clang-tidy clang-tidy-16
python3 python3-pip
clang-tidy clang-tidy-17
libboost-all-dev libeigen3-dev libgtk-3-dev libsqlite3-dev
gsl-bin libgsl-dev libgsl27
git ssh
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/.formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
image: ubuntu:rolling
strategy:
matrix:
version: [14, 15, 16]
version: [14, 15, 16, 17]
timeout-minutes: 60
steps:
# The following step is required in all jobs that use this repo's actions
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/.linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@ jobs:
git -C src/lorawan/ tag empty $(git hash-object -t tree /dev/null) &&
git -C src/lorawan/ diff -U0 empty
--src-prefix=a/src/lorawan/ --dst-prefix=b/src/lorawan/ |
clang-tidy-diff-16.py -path cmake-cache/ -p1 -quiet -use-color
clang-tidy-diff-17.py -path cmake-cache/ -p1 -quiet -use-color
-iregex "src\/lorawan\/.+\.(cpp|cc|cxx|c|h|hpp)"
1> $CLANG_TIDY_OUTPUT
2> /dev/null
- name: "Check job results"
run: |
(! egrep -A 3 "error:|warning:|note:" $CLANG_TIDY_OUTPUT)
(! egrep -v "file not found \[clang-diagnostic-error\]" $CLANG_TIDY_OUTPUT | egrep -A3 "error:|warning:|note:")
echo "No clang-tidy errors found"
- if: failure()
name: "Upload clang-tidy-output.log"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/.test-doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ jobs:
- name: "Check documentation coverage and formatting"
run: |
doc/doxygen.warnings.report.sh -i -m lorawan
python3 utils/check-style-clang-format.py --no-formatting --no-tabs doc/introspected-doxygen.h
python3 utils/check-style-clang-format.py --no-formatting --no-tabs doc/introspected-command-line.h
python3 utils/check-style-clang-format.py --no-formatting --no-tabs doc/introspected-doxygen.h doc/introspected-command-line.h
./ns3 clean
doxygen -v
- name: "Upload doxygen warnings as artifact"
if: always()
uses: actions/upload-artifact@v4
Expand Down
2 changes: 1 addition & 1 deletion NS3-VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
release ns-3.40
release ns-3.41
4 changes: 2 additions & 2 deletions model/adr-component.cc
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ AdrComponent::GetTypeId()
.AddAttribute("MultipleGwCombiningMethod",
"Whether to average the received power of gateways or to use the maximum",
EnumValue(AdrComponent::AVERAGE),
MakeEnumAccessor(&AdrComponent::tpAveraging),
MakeEnumAccessor<CombiningMethod>(&AdrComponent::tpAveraging),
MakeEnumChecker(AdrComponent::AVERAGE,
"avg",
AdrComponent::MAXIMUM,
Expand All @@ -53,7 +53,7 @@ AdrComponent::GetTypeId()
.AddAttribute("MultiplePacketsCombiningMethod",
"Whether to average SNRs from multiple packets or to use the maximum",
EnumValue(AdrComponent::AVERAGE),
MakeEnumAccessor(&AdrComponent::historyAveraging),
MakeEnumAccessor<CombiningMethod>(&AdrComponent::historyAveraging),
MakeEnumChecker(AdrComponent::AVERAGE,
"avg",
AdrComponent::MAXIMUM,
Expand Down
2 changes: 1 addition & 1 deletion model/end-device-lorawan-mac.cc
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ EndDeviceLorawanMac::GetTypeId()
.AddAttribute("MType",
"Specify type of message will be sent by this ED.",
EnumValue(LorawanMacHeader::UNCONFIRMED_DATA_UP),
MakeEnumAccessor(&EndDeviceLorawanMac::m_mType),
MakeEnumAccessor<LorawanMacHeader::MType>(&EndDeviceLorawanMac::m_mType),
MakeEnumChecker(LorawanMacHeader::UNCONFIRMED_DATA_UP,
"Unconfirmed",
LorawanMacHeader::CONFIRMED_DATA_UP,
Expand Down

0 comments on commit 792728d

Please sign in to comment.