Skip to content

Add GPX importer with linked geolocation objects - #1122

Merged
adulau merged 6 commits into
mainfrom
feat/gpx-import
Nov 13, 2026
Merged

adulau merged 6 commits into
mainfrom
feat/gpx-import

Conversation

@adulau

@adulau adulau commented Nov 13, 2026 •

Copy link
Copy Markdown
Member

Add gpx_import to import GPX 1.0 and 1.1 as a gpx object containing the original attachment, hashes, metadata, point counts and computed bounds. Every waypoint, route point and track point becomes a linked geolocation object with WGS84 coordinates, elevation, observation time and point context. Geographic observations have to_ids=false.

The module accepts file/paste input through the standard import interface, uses the existing PyMISP templates and requires no new dependencies. Input is limited to 20 MiB, 10,000 points and 32 XML nesting levels; DTDs and invalid point data reject the entire import. Includes API usage and field-mapping documentation.

Validation:

  • 80 importer tests, including real PyMISP objects, GPX versions/namespaces, metadata, precise coordinates, malformed input, limits and HTTP discovery/query handling.
  • 205 tests passed with the DMARC and CSV importer regression tests.
  • Black, isort, flake8 and whitespace checks passed.
  • Tested together with the separate GPX exporter: GPX 1.0 and 1.1 attachments survive import/export byte for byte; exported geolocation waypoints validate against the official GPX 1.1 schema.

Includes the complete uploaded tests/fixtures/gpx/Morning_Walk.gpx (197,419 bytes). Its regression test checks all 606 observations, exact attachment recovery, hashes, bounds and object references. Codex findings are fixed with regression tests for invalid timezone offsets, valid 24:00:00 normalization across Python versions, structural-point limits that ignore vendor extension name collisions, and artifact hashing under FIPS restrictions.

Companion exporter: #1123 (merged). Its real-file tests and review corrections are in follow-up #1124. The importer can be merged independently.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-13T07:46:39.177773Z f1f16c0 Manual request
🔒 Security Review ✅ Completed 2026-11-13T07:22:25.827552Z 741ec08 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 741ec087f2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

adulau commented Nov 13, 2026

Copy link
Copy Markdown
Member Author

@codex review

Please review the current importer, including the complete Morning_Walk.gpx regression fixture. It imports as one GPX object and 606 linked geolocations; the test checks every coordinate, elevation and timestamp, bounds, counts, references, hashes and exact attachment recovery. The importer and nearby regression tests pass (162 tests).

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d7aad124ea

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

adulau commented Nov 13, 2026

Copy link
Copy Markdown
Member Author

@codex review

Please re-review the latest head, 4c7005e. The timezone-offset finding is fixed and covered by metadata/point rejection tests and valid boundary tests. The full Morning Walk fixture remains covered; 184 importer and nearby regression tests pass.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4c7005e925

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

adulau commented Nov 13, 2026

Copy link
Copy Markdown
Member Author

@codex review

Please review the final head fc84933. All three reported findings are fixed: timezone offsets, structural-point counting and version-independent 24:00:00 normalization. Each has regression tests; the exact uploaded Morning Walk fixture remains covered. All 204 importer and nearby regression checks pass. Exporter follow-up: #1124.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fc84933e9f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

adulau commented Nov 13, 2026

Copy link
Copy Markdown
Member Author

@codex review

Please verify the latest incremental correction in f1f16c0: artifact hashes now use usedforsecurity=False, with a FIPS-policy regression test. All previous findings are addressed and their threads resolved. All 205 importer and nearby regression checks pass; Morning Walk remains an exact attachment-preservation test.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🎉

Reviewed commit: f1f16c0e15

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@adulau
adulau merged commit 7bfef1c into main Nov 13, 2026
7 checks passed
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.

1 participant