Skip to content

fix: properly check network already added#2336

Merged
frankiejol merged 1 commit into
mainfrom
fix/2335_init_net
May 27, 2026
Merged

fix: properly check network already added#2336
frankiejol merged 1 commit into
mainfrom
fix/2335_init_net

Conversation

@frankiejol
Copy link
Copy Markdown
Member

closes #2335

Copilot AI review requested due to automatic review settings May 26, 2026 10:20
@frankiejol frankiejol added this to the v2.4.7 milestone May 26, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes first-run internal network initialization so Ravada doesn’t mis-detect “already added” networks and accidentally insert duplicates (issue #2335).

Changes:

  • Replace the duplicated/insufficient “internal network already exists” check with a full scan of existing networks.
  • Track existing network addresses to avoid inserting routes with an address already present in networks.
  • Fix the address de-duplication bug ($done{address}$done{$address}).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread lib/Ravada.pm
($found) = $sth->fetchrow;
return if $found;
while ( my $row = $sth->fetchrow_hashref) {
return if $row->{name} =~ /^internal/;
@frankiejol frankiejol merged commit 0f4f759 into main May 27, 2026
2 checks passed
@frankiejol frankiejol deleted the fix/2335_init_net branch May 27, 2026 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Internal networks initialization is wrong

2 participants