internlm/SWE-Fixer-Train-110K huggingface dataset:
Repository: GeotrekCE/Geotrek-admin

Issue:
Infrastructure CONDITION - Should not be mandatory
Many will just localize their infrastructures. 



Discussion:

Resolving patch:
diff --git a/geotrek/infrastructure/models.py b/geotrek/infrastructure/models.py
--- a/geotrek/infrastructure/models.py
+++ b/geotrek/infrastructure/models.py
@@ -76,7 +76,7 @@ class BaseInfrastructure(MapEntityMixin, Topology, StructureRelated):
                                    verbose_name=_("Description"), help_text=_(u"Specificites"))
     type = models.ForeignKey(InfrastructureType, db_column='type', verbose_name=_("Type"))
     condition = models.ForeignKey(InfrastructureCondition, db_column='etat',
-                                  verbose_name=_("Condition"), null=True,
+                                  verbose_name=_("Condition"), blank=True, null=True,
                                   on_delete=models.PROTECT)
 
     class Meta:


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
Fix translations in package
The compilemessages step for geotrek and mapentity is missing somewhere


Discussion:
Reopen. Translations are compiled during installation but not copied in package.

Resolving patch:
diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -1,23 +1,24 @@
 #!/usr/bin/python3
 import os
 import distutils.command.build
+from pathlib import Path
 from setuptools import setup, find_packages
+from shutil import copy
 
 here = os.path.abspath(os.path.dirname(__file__))
 
 
 class BuildCommand(distutils.command.build.build):
     def run(self):
-        print("before")
         distutils.command.build.build.run(self)
-        print("after")
         from django.core.management import call_command
         curdir = os.getcwd()
-        os.chdir(os.path.join(curdir, 'geotrek'))
-        call_command('compilemessages')
-        os.chdir(os.path.join(curdir, 'mapentity'))
-        call_command('compilemessages')
-        os.chdir(curdir)
+        for subdir in ('geotrek', 'mapentity'):
+            os.chdir(subdir)
+            call_command('compilemessages')
+            for path in Path('.').rglob('*.mo'):
+                copy(path, os.path.join(curdir, self.build_lib, subdir, path))
+            os.chdir(curdir)
 
 
 setup(


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
Fixer la migration vers la 2.44.0
- [x] champs de traductions _xx créés avec NOT NULL et donc impossible à créer
- [x] géométries des sites à transformer en geometrycollection


Discussion:

Resolving patch:
diff --git a/geotrek/outdoor/migrations/0003_auto_20201214_1408.py b/geotrek/outdoor/migrations/0003_auto_20201214_1408.py
--- a/geotrek/outdoor/migrations/0003_auto_20201214_1408.py
+++ b/geotrek/outdoor/migrations/0003_auto_20201214_1408.py
@@ -17,10 +17,17 @@ class Migration(migrations.Migration):
             name='site',
             options={'ordering': ('name',), 'verbose_name': 'Outdoor site', 'verbose_name_plural': 'Outdoor sites'},
         ),
-        migrations.AlterField(
-            model_name='site',
-            name='geom',
-            field=django.contrib.gis.db.models.fields.GeometryCollectionField(srid=settings.SRID, verbose_name='Location'),
+        migrations.SeparateDatabaseAndState(
+            database_operations=[
+                migrations.RunSQL('ALTER TABLE "outdoor_site" ALTER COLUMN "geom" TYPE geometry(GeometryCollection,2154) USING ST_ForceCollection(geom);')
+            ],
+            state_operations=[
+                migrations.AlterField(
+                    model_name='site',
+                    name='geom',
+                    field=django.contrib.gis.db.models.fields.GeometryCollectionField(srid=settings.SRID, verbose_name='Location'),
+                ),
+            ]
         ),
         migrations.AlterField(
             model_name='sitepractice',


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
Outdoor - Orientations
- [x] Ajouter les noms des champs dans les filtres


Discussion:
OK, intégré dans la 2.44.0 : 

![image](https://user-images.githubusercontent.com/4418840/102685416-ad3f0400-41e0-11eb-873a-b139cd8b75fe.png)

Mais dans les filtres de la liste des sites, le champs de l'orientation et du vent ne sont pas nommés, du coup on ne peut pas les distinguer : 

![image](https://user-images.githubusercontent.com/4418840/102685442-dd86a280-41e0-11eb-9f6c-16d4c17e8ecf.png)

Resolving patch:
diff --git a/mapentity/filters.py b/mapentity/filters.py
--- a/mapentity/filters.py
+++ b/mapentity/filters.py
@@ -2,6 +2,7 @@
 from django.conf import settings
 
 from django_filters import FilterSet, Filter
+from django_filters.fields import ChoiceField
 from django_filters.filterset import get_model_field
 from django.contrib.gis import forms
 
@@ -42,6 +43,9 @@ def filter(self, qs, value):
 class BaseMapEntityFilterSet(FilterSet):
     def __init__(self, *args, **kwargs):
         super(BaseMapEntityFilterSet, self).__init__(*args, **kwargs)
+        for filter_ in self.filters.values():
+            if filter_.field_class == ChoiceField:
+                filter_.extra.setdefault('empty_label', filter_.label)
         self.__bypass_labels()
 
     def __bypass_labels(self):


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
Outdoor - Ordre sur le échelles de cotations



Discussion:

Resolving patch:
diff --git a/geotrek/outdoor/admin.py b/geotrek/outdoor/admin.py
--- a/geotrek/outdoor/admin.py
+++ b/geotrek/outdoor/admin.py
@@ -28,7 +28,7 @@ class SiteTypeAdmin(MergeActionMixin, TranslationAdmin):
 
 @admin.register(RatingScale)
 class RatingScaleAdmin(MergeActionMixin, TranslationAdmin):
-    list_display = ('name', 'practice')
+    list_display = ('name', 'practice', 'order')
     list_filter = ('practice', )
     search_fields = ('name', )
     merge_field = 'name'
diff --git a/geotrek/outdoor/migrations/0013_auto_20210122_1031.py b/geotrek/outdoor/migrations/0013_auto_20210122_1031.py
new file mode 100644
--- /dev/null
+++ b/geotrek/outdoor/migrations/0013_auto_20210122_1031.py
@@ -0,0 +1,22 @@
+# Generated by Django 3.1.5 on 2021-01-22 10:31
+
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('outdoor', '0012_auto_20210122_1029'),
+    ]
+
+    operations = [
+        migrations.AlterModelOptions(
+            name='ratingscale',
+            options={'ordering': ('practice', 'order', 'name'), 'verbose_name': 'Rating scale', 'verbose_name_plural': 'Rating scales'},
+        ),
+        migrations.AddField(
+            model_name='ratingscale',
+            name='order',
+            field=models.IntegerField(blank=True, help_text='Within a practice. Alphabetical order if blank', null=True, verbose_name='Order'),
+        ),
+    ]
diff --git a/geotrek/outdoor/models.py b/geotrek/outdoor/models.py
--- a/geotrek/outdoor/models.py
+++ b/geotrek/outdoor/models.py
@@ -32,6 +32,8 @@ class RatingScale(models.Model):
     name = models.CharField(verbose_name=_("Name"), max_length=128)
     practice = models.ForeignKey(Practice, related_name="rating_scales", on_delete=models.PROTECT,
                                  verbose_name=_("Practice"))
+    order = models.IntegerField(verbose_name=_("Order"), null=True, blank=True,
+                                help_text=_("Within a practice. Alphabetical order if blank"))
 
     def __str__(self):
         return "{} ({})".format(self.name, self.practice.name)
@@ -39,7 +41,7 @@ def __str__(self):
     class Meta:
         verbose_name = _("Rating scale")
         verbose_name_plural = _("Rating scales")
-        ordering = ('practice', 'name')
+        ordering = ('practice', 'order', 'name')
 
 
 class Rating(models.Model):


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
API V2 - Treks et fichiers liés
Dans la route des treks, on a l'URL des fichiers GPX et KML mais pas celle des PDF de la rando.
A priori je pense qu'il faut l'ajouter.
Avec les 2 URL (PDF de base, ou PDF livret)


Discussion:
Idem pour les contenus touristiques et à terme les autres objets contenant des PDF (evenements touristiques, sites outdoor...)
La propriété "pdf" a été ajoutée dans l'API de la version 2.47.0. 
Mais son chemin est relatif, alors que pour les autres fichiers (gpx, kml, images...), les URL sont en absolu.
En absolu serait mieux pour homogénéiser et c'est plus simple à utiliser.

Resolving patch:
diff --git a/geotrek/api/v2/serializers.py b/geotrek/api/v2/serializers.py
--- a/geotrek/api/v2/serializers.py
+++ b/geotrek/api/v2/serializers.py
@@ -288,7 +288,11 @@ def get_pdf_url(self, obj):
                 if not common_models.Attachment.objects.attachments_for_object_only_type(obj, file_type).exists():
                     return None
             urlname = 'tourism:touristiccontent_{}printable'.format('booklet_' if settings.USE_BOOKLET_PDF else '')
-            return reverse(urlname, kwargs={'lang': get_language(), 'pk': obj.pk, 'slug': obj.slug})
+            url = reverse(urlname, kwargs={'lang': get_language(), 'pk': obj.pk, 'slug': obj.slug})
+            request = self.context.get('request')
+            if request:
+                url = request.build_absolute_uri(url)
+            return url
 
     class InformationDeskTypeSerializer(DynamicFieldsMixin, serializers.ModelSerializer):
         label = serializers.SerializerMethodField(read_only=True)
@@ -436,8 +440,12 @@ def get_pdf_url(self, obj):
                 file_type = get_object_or_404(common_models.FileType, type="Topoguide")
                 if not common_models.Attachment.objects.attachments_for_object_only_type(obj, file_type).exists():
                     return None
-            return reverse('trekking:trek_{}printable'.format('booklet_' if settings.USE_BOOKLET_PDF else ''),
-                           kwargs={'lang': get_language(), 'pk': obj.pk, 'slug': obj.slug})
+            url = reverse('trekking:trek_{}printable'.format('booklet_' if settings.USE_BOOKLET_PDF else ''),
+                          kwargs={'lang': get_language(), 'pk': obj.pk, 'slug': obj.slug})
+            request = self.context.get('request')
+            if request:
+                url = request.build_absolute_uri(url)
+            return url
 
         def get_advice(self, obj):
             return get_translation_or_dict('advice', self, obj)


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
API V2 - Manque les id des sources sur la route /source/



Discussion:
Idem sur la route des lieux d'information : /informationdesk/

Resolving patch:
diff --git a/geotrek/api/v2/serializers.py b/geotrek/api/v2/serializers.py
--- a/geotrek/api/v2/serializers.py
+++ b/geotrek/api/v2/serializers.py
@@ -150,7 +150,7 @@ class Meta:
 class RecordSourceSerializer(DynamicFieldsMixin, serializers.ModelSerializer):
     class Meta:
         model = common_models.RecordSource
-        fields = ('name', 'pictogram', 'website')
+        fields = ('id', 'name', 'pictogram', 'website')
 
 
 class AttachmentSerializer(DynamicFieldsMixin, serializers.ModelSerializer):
@@ -322,7 +322,7 @@ class Meta:
             model = tourism_models.InformationDesk
             geo_field = 'geom'
             fields = (
-                'description', 'email', 'latitude', 'longitude',
+                'id', 'description', 'email', 'latitude', 'longitude',
                 'municipality', 'name', 'phone', 'photo_url',
                 'postal_code', 'street', 'type', 'website'
             )


Test patch:
diff --git a/geotrek/api/tests/test_v2.py b/geotrek/api/tests/test_v2.py
--- a/geotrek/api/tests/test_v2.py
+++ b/geotrek/api/tests/test_v2.py
@@ -93,12 +93,12 @@
 TREK_LABEL_PROPERTIES_JSON_STRUCTURE = sorted(['id', 'advice', 'filter', 'name', 'pictogram'])
 
 INFORMATION_DESK_PROPERTIES_JSON_STRUCTURE = sorted([
-    'description', 'email', 'latitude', 'longitude',
+    'id', 'description', 'email', 'latitude', 'longitude',
     'municipality', 'name', 'phone', 'photo_url',
     'postal_code', 'street', 'type', 'website'
 ])
 
-SOURCE_PROPERTIES_JSON_STRUCTURE = sorted(['name', 'pictogram', 'website'])
+SOURCE_PROPERTIES_JSON_STRUCTURE = sorted(['id', 'name', 'pictogram', 'website'])
 
 RESERVATION_SYSTEM_PROPERTIES_JSON_STRUCTURE = sorted(['name', 'id'])
Repository: GeotrekCE/Geotrek-admin

Issue:
API V2 - Touristic content categories languages
J'ai traduit en anglais les labels des catégories de contenus touristiques sur notre serveur DEMO, mais quand j'appelle la route en Anglais, les catégories de contenus touristiques sont renvoyées en français : https://geotrekdemo.ecrins-parcnational.fr/api/v2/touristiccontent_category/?language=en


Discussion:

Resolving patch:
diff --git a/geotrek/api/v2/serializers.py b/geotrek/api/v2/serializers.py
--- a/geotrek/api/v2/serializers.py
+++ b/geotrek/api/v2/serializers.py
@@ -219,6 +219,7 @@ class Meta:
 if 'geotrek.tourism' in settings.INSTALLED_APPS:
     class TouristicContentCategorySerializer(DynamicFieldsMixin, serializers.ModelSerializer):
         types = serializers.SerializerMethodField(read_only=True)
+        label = serializers.SerializerMethodField(read_only=True)
 
         class Meta:
             model = tourism_models.TouristicContentCategory
@@ -227,14 +228,17 @@ class Meta:
         def get_types(self, obj):
             return [{
                 'id': obj.id * 100 + i,
-                'label': getattr(obj, 'type{}_label'.format(i)),
+                'label': get_translation_or_dict('type{}_label'.format(i), self, obj),
                 'values': [{
                     'id': t.id,
-                    'label': t.label,
+                    'label': get_translation_or_dict('label', self, t),
                     'pictogram': t.pictogram.url if t.pictogram else None,
                 } for t in obj.types.filter(in_list=i)]
             } for i in (1, 2)]
 
+        def get_label(self, obj):
+            return get_translation_or_dict('label', self, obj)
+
     class TouristicContentSerializer(DynamicFieldsMixin, serializers.ModelSerializer):
         url = HyperlinkedIdentityField(view_name='apiv2:touristiccontent-detail')
         geometry = geo_serializers.GeometryField(read_only=True, source="geom_transformed", precision=7)


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
API V2 - Treks fields languages
Quand on interroge l'API dans une langue différente de celle par défaut, certains contenus de champs sont quand même renvoyés  dans la langue par défaut.

Exemple : https://geotrek-admin.ecrins-parcnational.fr/api/v2/trek/903303/?language=en&omit=geometry
Les champs "access" et "ambiance" sont renvoyés en français, alors qu'ils ont été traduits en anglais.

Idem sur d'autres champs de treks et/ou de touristic_contents ?


Discussion:
Il manque aussi disabled_infrastructure. Pour le reste ça a l'air OK pour tout ce qui concerne trek & tourism.


Resolving patch:
diff --git a/geotrek/api/v2/serializers.py b/geotrek/api/v2/serializers.py
--- a/geotrek/api/v2/serializers.py
+++ b/geotrek/api/v2/serializers.py
@@ -374,9 +374,12 @@ class TrekSerializer(DynamicFieldsMixin, serializers.ModelSerializer):
         length_2d = serializers.SerializerMethodField(read_only=True)
         length_3d = serializers.SerializerMethodField(read_only=True)
         name = serializers.SerializerMethodField(read_only=True)
+        access = serializers.SerializerMethodField(read_only=True)
+        ambiance = serializers.SerializerMethodField(read_only=True)
         description = serializers.SerializerMethodField(read_only=True)
         description_teaser = serializers.SerializerMethodField(read_only=True)
         departure = serializers.SerializerMethodField(read_only=True)
+        disabled_infrastructure = serializers.SerializerMethodField(read_only=True)
         departure_geom = serializers.SerializerMethodField(read_only=True)
         arrival = serializers.SerializerMethodField(read_only=True)
         external_id = serializers.CharField(source='eid')
@@ -416,6 +419,15 @@ def get_name(self, obj):
         def get_description(self, obj):
             return get_translation_or_dict('description', self, obj)
 
+        def get_access(self, obj):
+            return get_translation_or_dict('access', self, obj)
+
+        def get_ambiance(self, obj):
+            return get_translation_or_dict('ambiance', self, obj)
+
+        def get_disabled_infrastructure(self, obj):
+            return get_translation_or_dict('disabled_infrastructure', self, obj)
+
         def get_departure(self, obj):
             return get_translation_or_dict('departure', self, obj)
 


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
Static pages images URL ?
J'ai ajouté une cover_image à une page statique sur le serveur de DEMO sur cette page : https://geotrekdemo.ecrins-parcnational.fr/admin/flatpages/flatpage/3/change/ (admin / admin)

L'URL de l'image indiquée (dans l'Adminsite et dans l'API V2) est https://geotrekdemo.ecrins-parcnational.fr/media/paperclip/flatpages_flatpage/3/biodivecrins.jpg, mais elle n'est pas accessible.

L'image est bien sur mon serveur dans /opt/geotrek-admin/var/media/paperclip/flatpages_flatpage/3/


Discussion:

Resolving patch:
diff --git a/geotrek/flatpages/models.py b/geotrek/flatpages/models.py
--- a/geotrek/flatpages/models.py
+++ b/geotrek/flatpages/models.py
@@ -108,3 +108,6 @@ def rando_url(self):
     @property
     def meta_description(self):
         return plain_text(self.content)[:500]
+
+    def is_public(self):
+        return self.any_published
diff --git a/mapentity/views/base.py b/mapentity/views/base.py
--- a/mapentity/views/base.py
+++ b/mapentity/views/base.py
@@ -39,7 +39,7 @@ def serve_attachment(request, path):
     original_path = re.sub(r'\.\d+x\d+_q\d+(_crop)?\.(jpg|png|jpeg)$', '', path, count=1, flags=re.IGNORECASE)
     attachment = get_object_or_404(get_attachment_model(), attachment_file=original_path)
     obj = attachment.content_object
-    if not issubclass(obj._meta.model, mapentity_models.MapEntityMixin):
+    if not hasattr(obj._meta.model, 'attachments'):
         raise Http404
     if not obj.is_public():
         if not request.user.is_authenticated:


Test patch:
diff --git a/geotrek/flatpages/tests/test_models.py b/geotrek/flatpages/tests/test_models.py
--- a/geotrek/flatpages/tests/test_models.py
+++ b/geotrek/flatpages/tests/test_models.py
@@ -52,3 +52,7 @@ def test_retrieve_by_id_if_order_is_the_same(self):
         finally:
             for f in fp:
                 f.clean()
+
+    def test_is_public(self):
+        fp = FlatPageFactory(title="Blabla", published_fr=True)
+        self.assertTrue(fp.is_public())
Repository: GeotrekCE/Geotrek-admin

Issue:
Personnalisation plus facile de loadpaths
J'ai un cas où j'aimerais importer un gros fichier Shape, mais où j'aimerais filtrer selon certains attributs de chaque élément. Pour éviter de devoir réécrire ma propre command `loadpaths` complète, il serait pratique de déporter le filtrage des objets dans une méthode de la commande. Le patch proposé arrive...


Discussion:

Resolving patch:
diff --git a/geotrek/core/management/commands/loadpaths.py b/geotrek/core/management/commands/loadpaths.py
--- a/geotrek/core/management/commands/loadpaths.py
+++ b/geotrek/core/management/commands/loadpaths.py
@@ -37,7 +37,7 @@ def handle(self, *args, **options):
         structure = options.get('structure')
         name_column = options.get('name')
         srid = options.get('srid')
-        do_intersect = options.get('intersect')
+        self.do_intersect = options.get('intersect')
         comments_columns = options.get('comment')
         fail = options.get('fail')
         dry = options.get('dry')
@@ -64,8 +64,8 @@ def handle(self, *args, **options):
 
         ds = DataSource(file_path, encoding=encoding)
 
-        bbox = Polygon.from_bbox(settings.SPATIAL_EXTENT)
-        bbox.srid = settings.SRID
+        self.bbox = Polygon.from_bbox(settings.SPATIAL_EXTENT)
+        self.bbox.srid = settings.SRID
 
         sid = transaction.savepoint()
 
@@ -84,7 +84,7 @@ def handle(self, *args, **options):
                     break
                 self.check_srid(srid, geom)
                 geom.dim = 2
-                if do_intersect and bbox.intersects(geom) or not do_intersect and geom.within(bbox):
+                if self.should_import(feat, geom):
                     try:
                         with transaction.atomic():
                             comment_final = '</br>'.join(comment_final_tab)
@@ -121,3 +121,9 @@ def check_srid(self, srid, geom):
                 geom.transform(settings.SRID)
             except GDALException:
                 raise CommandError("SRID is not well configurate, change/add option srid")
+
+    def should_import(self, feature, geom):
+        return (
+            self.do_intersect and self.bbox.intersects(geom)
+            or not self.do_intersect and geom.within(self.bbox)
+        )


Test patch:
Repository: GeotrekCE/Geotrek-admin

Issue:
Bug affichage intervention selon niveau de zoom
Bonjour, sur la 2.49.0 selon le niveau de zoom sélectionné, certaines interventions apparaissent et disparaissent. Faire glisser la carte provoque aussi ce comportement :


https://user-images.githubusercontent.com/45095227/108825316-2719b200-75c3-11eb-8406-11d57bcd2531.mov

J'en profite pour dire que je n'ai pas pu changer l'opacité des linéaires pour qu'ils soient plus visibles ( voir : https://github.com/GeotrekCE/Geotrek-admin/issues/2554)


Discussion:
En effet je viens de constater un soucis similaire sur ma production en 2.51.1.
Quand j'arrive sur le module Interventions, parfois les interventions s'affichent sur la carte mais pas dans la liste. Parfois elles disparaissent aussi de la carte.

![image](https://user-images.githubusercontent.com/4418840/110763644-68ac8d00-8252-11eb-936f-0e0f06ab7e60.png)

Constaté aussi de notre côté. Version 2.51.1 également.

Resolving patch:
diff --git a/geotrek/maintenance/filters.py b/geotrek/maintenance/filters.py
--- a/geotrek/maintenance/filters.py
+++ b/geotrek/maintenance/filters.py
@@ -25,6 +25,9 @@ def get_geom(self, value):
     def filter(self, qs, values):
         if not values:
             return qs
+        if not isinstance(values, list):
+            values = [values]
+
         lookup = self.lookup_expr
 
         blade_content_type = ContentType.objects.get_for_model(Blade)


Test patch:
diff --git a/geotrek/maintenance/tests/test_filters.py b/geotrek/maintenance/tests/test_filters.py
--- a/geotrek/maintenance/tests/test_filters.py
+++ b/geotrek/maintenance/tests/test_filters.py
@@ -31,6 +31,19 @@ def setUpTestData(cls):
         InterventionFactory.create(target=topo_1)
         cls.seek_inter = InterventionFactory.create(target=seek_topo)
 
+    def test_in_bbox(self):
+        xmin, ymin, xmax, ymax = self.seek_inter.geom.transform(settings.API_SRID, clone=True).extent
+        bbox = Polygon([[xmin - 1, ymin - 1], [xmin - 1, ymax + 1], [xmax + 1, ymax + 1], [xmax + 1, ymin - 1], [xmin - 1, ymin - 1]])
+        qs = InterventionFilterSet({'bbox': bbox.wkt}).qs
+        self.assertEqual(len(qs), 1)
+        self.assertEqual(qs[0], self.seek_inter)
+
+    def test_out_bbox(self):
+        xmin, ymin, xmax, ymax = self.seek_inter.geom.transform(settings.API_SRID, clone=True).extent
+        bbox = Polygon([[xmax + 1, ymax + 1], [xmax + 1, ymax + 2], [xmax + 2, ymax + 2], [xmax + 2, ymax + 1], [xmax + 1, ymax + 1]])
+        qs = InterventionFilterSet({'bbox': bbox.wkt}).qs
+        self.assertEqual(len(qs), 0)
+
     def test_filter_by_physical_edge(self):
         edge = PhysicalEdgeFactory(paths=[self.seek_path])