gabriel / musehub public
fix BREAKING task/test-suite-fixes #12 / 12
AI Agent gabriel · 148 days ago · Apr 27, 2026 · Diff

fix: canonical content IDs throughout — coord column widths, UUID fallbacks removed, test suite fixes, compliance migration stub

sha256:de2f3000147eb23e3ef8a8aa2a04edebe09ebd437a014670993a543691891fe2 sha
+209 ~204 −27 symbols
sha256:1bba3a236655e6398b1d8530ea81c496729a602c4a6f9b005170ac9f86c5963b snapshot
+209
symbols added
~204
symbols modified
−27
symbols removed
0
dead code introduced
Semantic Changes 440 symbols
+ branch_labels variable variable branch_labels L17–17
+ depends_on variable variable depends_on L18–18
+ down_revision variable variable down_revision L16–16
+ downgrade function function downgrade L36–39
+ annotations import import annotations L10–10
+ op import import op L12–12
+ sa import import sa L13–13
+ revision variable variable revision L15–15
+ upgrade function function upgrade L21–33
~ musehub/db/coord_models.py .py 2 symbols removed, 3 symbols modified
_new_uuid function function _new_uuid L46–47
uuid import import uuid L35–35 → moved to tests/test_security_hardening.py
~ musehub/mcp/sse.py .py 1 symbol modified
~ musehub/models/musehub_auth.py .py 1 symbol modified
~ musehub/muse_cli/snapshot.py .py 1 symbol added, 3 symbols modified
+ split_id import import split_id L15–15
~ musehub/protocol/responses.py .py 1 symbol added, 2 symbols removed, 1 symbol modified
blob_id import import blob_id L8–8
json import import json L4–4 → moved to tests/test_cross_repo.py
+ content_hash import import content_hash L6–6
~ musehub/services/musehub_coord_server.py .py 1 symbol added, 3 symbols modified
+ fake_id import import fake_id L27–27
~ musehub/services/musehub_divergence.py .py 4 symbols added, 2 symbols modified
+ _SECTION_KEYWORDS variable variable _SECTION_KEYWORDS L70–73
+ _SECTION_RE variable variable _SECTION_RE L74–77
+ extract_affected_sections function function extract_affected_sections L80–93
+ re import import re L33–33
~ tests/conftest.py .py 3 symbols modified
~ tests/test_agent_registration.py .py 2 symbols added, 2 symbols removed, 4 symbols modified
base64 import import base64 L12–12
hashlib import import hashlib L13–13
+ encode_pubkey import import encode_pubkey L19–19
+ public_key_fingerprint import import public_key_fingerprint L19–19
~ tests/test_api_performance.py .py 1 symbol added, 2 symbols modified
~ tests/test_context.py .py 1 symbol added, 4 symbols modified
+ fake_id import import fake_id L26–26
~ tests/test_cross_repo.py .py 2 symbols added, 3 symbols removed, 2 symbols modified
_pack_history function function _pack_history L88–90
MusehubSymbolIndex import import MusehubSymbolIndex L28–28
msgpack import import msgpack L22–22
+ MusehubIntelResult import import MusehubIntelResult L28–28
+ json import import json L22–22 ← moved from musehub/protocol/responses.py
~ tests/test_id_canonical.py .py 17 symbols added, 6 symbols removed, 6 symbols modified
_make_push_payload function function _make_push_payload L83–117
_mp function function _mp L79–80
_hashlib import import _hashlib L59–59
test_push_with_bare_hex_commit_id_returns_422 function async_function test_push_with_bare_hex_commit_id_returns_422 L320–339
test_push_with_bare_hex_snapshot_id_returns_422 function async_function test_push_with_bare_hex_snapshot_id_returns_422 L343–362
test_push_with_canonical_ids_returns_200 function async_function test_push_with_canonical_ids_returns_200 L297–316
+ _SFRAME_COMMIT_PACK variable variable _SFRAME_COMMIT_PACK L85–85
+ _SFRAME_END variable variable _SFRAME_END L86–86
+ _SFRAME_ERROR variable variable _SFRAME_ERROR L87–87
+ _SFRAME_HEADER variable variable _SFRAME_HEADER L84–84
+ _SFRAME_RESULT variable variable _SFRAME_RESULT L88–88
+ _fw variable variable _fw L82–82
+ _make_mwp_push function function _make_mwp_push L95–125
+ _parse_mwp_result function function _parse_mwp_result L128–130
+ _wrap function function _wrap L91–92
+ MuseWireFrameWriter import import MuseWireFrameWriter L34–34
+ WIRE_CONTENT_TYPE import import WIRE_CONTENT_TYPE L34–34
+ _long_id import import _long_id L68–68
+ blob_id import import blob_id L60–60
+ fake_id import import fake_id L60–60
+ test_push_with_bare_hex_commit_id_returns_error function async_function test_push_with_bare_hex_commit_id_returns_error L332–351
+ test_push_with_bare_hex_snapshot_id_returns_error function async_function test_push_with_bare_hex_snapshot_id_returns_error L355–374
+ test_push_with_canonical_ids_returns_ok function async_function test_push_with_canonical_ids_returns_ok L310–328
~ tests/test_musehub_auth_adversarial.py .py 3 symbols added, 3 symbols removed, 2 symbols modified
_b64url function function _b64url L40–41
_fp function function _fp L44–45
hashlib import import hashlib L22–22
+ encode_pubkey import import encode_pubkey L30–30
+ encode_sig import import encode_sig L30–30
+ public_key_fingerprint import import public_key_fingerprint L30–30
~ _kp
~ _sign
~ tests/test_musehub_auth_challenge_db.py .py 2 symbols added, 3 symbols removed, 3 symbols modified
_b64url function function _b64url L36–37
_fp function function _fp L40–41
base64 import import base64 L16–16
+ encode_pubkey import import encode_pubkey L18–18
+ encode_sig import import encode_sig L18–18
~ _kp
~ _sign
~ tests/test_musehub_contracts.py .py 1 symbol added, 1 symbol removed, 2 symbols modified
hashlib import import hashlib L14–14
+ content_hash import import content_hash L17–17
~ tests/test_object_store_canonical.py .py 1 symbol added, 3 symbols modified
+ fake_id import import fake_id L36–36
~ tests/test_protocol_introspection.py .py 3 symbols added, 3 symbols removed, 6 symbols modified
test_returns_64_char_hex_string method method test_returns_64_char_hex_string L79–83
test_get_protocol_hash_is_64_hex method async_method test_get_protocol_hash_is_64_hex L232–236
hashlib import import hashlib L12–12 → moved to tests/test_security_hardening.py
+ test_returns_canonical_id_string method method test_returns_canonical_id_string L79–85
+ test_get_protocol_hash_is_canonical_id method async_method test_get_protocol_hash_is_canonical_id L232–236
+ content_hash import import content_hash L16–16
~ tests/test_quota_via_refs.py .py 1 symbol added, 2 symbols modified
+ fake_id import import fake_id L27–27
~ tests/test_security_hardening.py .py 138 symbols added
+ TestAgentImpersonation class class TestAgentImpersonation L804–854
+ test_trusted_agent_ids_setting_exists method method test_trusted_agent_ids_setting_exists L805–809
+ test_unknown_agent_flagged_in_metadata method method test_unknown_agent_flagged_in_metadata L830–835
+ test_wire_push_checks_agent_ids method method test_wire_push_checks_agent_ids L811–815
+ test_wire_push_flags_not_rejects method method test_wire_push_flags_not_rejects L817–828
+ test_wire_push_stream_checks_trusted_prefix method method test_wire_push_stream_checks_trusted_prefix L848–854
+ test_wire_push_stream_flags_unknown_agents method method test_wire_push_stream_flags_unknown_agents L837–846
+ TestClickjacking class class TestClickjacking L629–654
+ test_csp_frame_ancestors_none method async_method test_csp_frame_ancestors_none L636–641
+ test_security_headers_middleware_sets_frame_ancestors method method test_security_headers_middleware_sets_frame_ancestors L650–654
+ test_security_headers_middleware_sets_x_frame_options method method test_security_headers_middleware_sets_x_frame_options L643–648
+ test_x_frame_options_deny method async_method test_x_frame_options_deny L630–634
+ TestCommitIdForgery class class TestCommitIdForgery L372–417
+ test_require_signed_commits_setting_exists method method test_require_signed_commits_setting_exists L373–377
+ test_wire_push_enforces_when_setting_true method method test_wire_push_enforces_when_setting_true L379–387
+ test_wire_push_source_has_unsigned_warning_not_rejection method method test_wire_push_source_has_unsigned_warning_not_rejection L400–417
+ test_wire_push_stream_enforces_signed_commits method method test_wire_push_stream_enforces_signed_commits L389–398
+ TestHandleSquatting class class TestHandleSquatting L697–731
+ test_auth_service_normalizes_handle_to_lowercase method method test_auth_service_normalizes_handle_to_lowercase L698–704
+ test_gabriel_and_gabriel_uppercase_normalize_to_same method method test_gabriel_and_gabriel_uppercase_normalize_to_same L721–726
+ test_handle_strip_applied method method test_handle_strip_applied L714–719
+ test_handle_with_spaces_stripped method method test_handle_with_spaces_stripped L728–731
+ test_lowercase_normalization_precedes_identity_creation method method test_lowercase_normalization_precedes_identity_creation L706–712
+ TestMagicBytes class class TestMagicBytes L523–622
+ _check method method _check L524–526
+ _expect_error method method _expect_error L528–531
+ test_empty_content_returns_empty method method test_empty_content_returns_empty L579–580
+ test_html_extension_allows_html_content method method test_html_extension_allows_html_content L605–608
+ test_jpeg_extension_but_zip_content_blocked method method test_jpeg_extension_but_zip_content_blocked L599–600
+ test_jpg_extension_but_html_content_blocked method method test_jpg_extension_but_html_content_blocked L590–591
+ test_midi_extension_but_html_content_blocked method method test_midi_extension_but_html_content_blocked L584–585
+ test_midi_extension_but_php_shebang_blocked method method test_midi_extension_but_php_shebang_blocked L587–588
+ test_mp3_extension_but_html_shebang_blocked method method test_mp3_extension_but_html_shebang_blocked L602–603
+ test_png_extension_but_wrong_magic_blocked method method test_png_extension_but_wrong_magic_blocked L596–597
+ test_script_shebang_in_py_file_allowed method method test_script_shebang_in_py_file_allowed L563–566
+ test_script_shebang_in_sh_file_allowed method method test_script_shebang_in_sh_file_allowed L568–570
+ test_shebang_still_blocked_in_binary_extensions method method test_shebang_still_blocked_in_binary_extensions L572–574
+ test_shebang_still_blocked_in_midi_extension method method test_shebang_still_blocked_in_midi_extension L576–577
+ test_unknown_extension_passes_through method method test_unknown_extension_passes_through L559–561
+ test_valid_jpeg method method test_valid_jpeg L555–557
+ test_valid_midi method method test_valid_midi L535–537
+ test_valid_mp3_id3 method method test_valid_mp3_id3 L539–541
+ test_valid_mp3_sync method method test_valid_mp3_sync L543–545
+ test_valid_png method method test_valid_png L551–553
+ test_valid_webp method method test_valid_webp L547–549
+ test_webp_extension_but_wrong_magic_blocked method method test_webp_extension_but_wrong_magic_blocked L593–594
+ test_wire_push_imports_magic_bytes method method test_wire_push_imports_magic_bytes L612–616
+ test_wire_push_rejects_polyglot_path method method test_wire_push_rejects_polyglot_path L618–622
+ TestMassAssignment class class TestMassAssignment L219–256
+ _route_files method method _route_files L220–221
+ test_no_kwargs_splat_from_request_body method method test_no_kwargs_splat_from_request_body L223–236
+ test_route_handler_body_params_are_pydantic_or_primitive method method test_route_handler_body_params_are_pydantic_or_primitive L238–250
+ test_webhook_create_uses_pydantic_not_raw_dict method method test_webhook_create_uses_pydantic_not_raw_dict L252–256
+ TestMcpPromptInjection class class TestMcpPromptInjection L738–797
+ test_delimiter_appears_in_success_path_not_error method method test_delimiter_appears_in_success_path_not_error L746–756
+ test_dispatcher_wraps_result_in_delimiter_tags method method test_dispatcher_wraps_result_in_delimiter_tags L739–744
+ test_healthz_tool_result_not_wrapped method async_method test_healthz_tool_result_not_wrapped L791–797
+ test_prompts_instructs_model_to_treat_tool_results_as_data method method test_prompts_instructs_model_to_treat_tool_results_as_data L758–763
+ test_prompts_instructs_treat_as_data_not_instructions method method test_prompts_instructs_treat_as_data_not_instructions L771–779
+ test_prompts_mentions_prompt_injection_risk method method test_prompts_mentions_prompt_injection_risk L765–769
+ test_prompts_names_user_controlled_fields method method test_prompts_names_user_controlled_fields L781–789
+ TestObjectEnumeration class class TestObjectEnumeration L309–365
+ _db_models_src method method _db_models_src L310–311
+ test_issue_number_is_per_repo_not_global method method test_issue_number_is_per_repo_not_global L336–344
+ test_issue_primary_key_is_uuid_string method method test_issue_primary_key_is_uuid_string L328–334
+ test_no_autoincrement_primary_keys_on_main_entities method method test_no_autoincrement_primary_keys_on_main_entities L346–365
+ test_repo_primary_key_is_uuid_string method method test_repo_primary_key_is_uuid_string L313–326
+ TestOpenRedirect class class TestOpenRedirect L661–690
+ test_elicitation_does_not_store_full_absolute_url method method test_elicitation_does_not_store_full_absolute_url L674–681
+ test_elicitation_path_only_for_both_routes method method test_elicitation_path_only_for_both_routes L683–690
+ test_elicitation_stores_path_only_in_next_param method method test_elicitation_stores_path_only_in_next_param L662–672
+ TestRegexDos class class TestRegexDos L424–478
+ _search_service_src method method _search_service_src L425–426
+ test_global_search_uses_sql_or_python_in method method test_global_search_uses_sql_or_python_in L469–478
+ test_no_user_supplied_regex_in_search_routes method method test_no_user_supplied_regex_in_search_routes L461–467
+ test_search_by_ask_uses_fixed_tokenizer_not_user_regex method method test_search_by_ask_uses_fixed_tokenizer_not_user_regex L446–459
+ test_search_by_pattern_uses_python_in_not_regex method method test_search_by_pattern_uses_python_in_not_regex L428–444
+ TestSsrfCheckUrlSafe class class TestSsrfCheckUrlSafe L38–94
+ _check method method _check L39–41
+ test_empty_string_blocked method method test_empty_string_blocked L92–94
+ test_file_scheme_blocked method method test_file_scheme_blocked L55–57
+ test_ftp_scheme_blocked method method test_ftp_scheme_blocked L51–53
+ test_hostname_with_path_allowed method method test_hostname_with_path_allowed L84–86
+ test_http_scheme_blocked method method test_http_scheme_blocked L47–49
+ test_https_public_url_allowed method method test_https_public_url_allowed L43–45
+ test_link_local_169_254_blocked method method test_link_local_169_254_blocked L79–82
+ test_loopback_127_blocked method method test_loopback_127_blocked L59–61
+ test_loopback_127_other_blocked method method test_loopback_127_other_blocked L63–65
+ test_no_hostname_blocked method method test_no_hostname_blocked L88–90
+ test_rfc1918_10_blocked method method test_rfc1918_10_blocked L67–69
+ test_rfc1918_172_16_blocked method method test_rfc1918_172_16_blocked L71–73
+ test_rfc1918_192_168_blocked method method test_rfc1918_192_168_blocked L75–77
+ TestSsrfValidateOutboundUrl class class TestSsrfValidateOutboundUrl L101–143
+ test_bare_ip_does_not_do_dns method async_method test_bare_ip_does_not_do_dns L136–143
+ test_dns_resolves_to_loopback_blocked method async_method test_dns_resolves_to_loopback_blocked L120–126
+ test_dns_resolves_to_private_blocked method async_method test_dns_resolves_to_private_blocked L111–118
+ test_public_hostname_allowed method async_method test_public_hostname_allowed L102–109
+ test_unresolvable_hostname_blocked method async_method test_unresolvable_hostname_blocked L128–134
+ TestTarBomb class class TestTarBomb L485–500
+ test_no_archive_extraction_in_codebase method method test_no_archive_extraction_in_codebase L486–500
+ TestTimingAttacks class class TestTimingAttacks L263–302
+ test_compare_digest_used_not_equal_for_secrets method method test_compare_digest_used_not_equal_for_secrets L281–302
+ test_crypto_keys_uses_compare_digest method method test_crypto_keys_uses_compare_digest L275–279
+ test_request_signing_uses_cryptographic_verify method method test_request_signing_uses_cryptographic_verify L264–273
+ TestWebhookCreateSsrf class class TestWebhookCreateSsrf L150–177
+ _create method method _create L151–153
+ test_aws_metadata_endpoint_rejected method method test_aws_metadata_endpoint_rejected L174–177
+ test_http_rejected_at_model_parse method method test_http_rejected_at_model_parse L159–162
+ test_https_public_accepted method method test_https_public_accepted L155–157
+ test_loopback_rejected_at_model_parse method method test_loopback_rejected_at_model_parse L169–172
+ test_rfc1918_rejected_at_model_parse method method test_rfc1918_rejected_at_model_parse L164–167
+ TestWebhookDeliveryDefenseInDepth class class TestWebhookDeliveryDefenseInDepth L184–212
+ test_delivery_blocked_when_ssrf_check_fails method async_method test_delivery_blocked_when_ssrf_check_fails L185–206
+ test_dispatcher_imports_ssrf_module method method test_dispatcher_imports_ssrf_module L208–212
+ _AUTH_SVC variable variable _AUTH_SVC L511–511
+ _CONFIG variable variable _CONFIG L515–515
+ _DISPATCHER variable variable _DISPATCHER L29–29
+ _ELICITATION variable variable _ELICITATION L510–510
+ _MAGIC_BYTES variable variable _MAGIC_BYTES L516–516
+ _MAIN_PY variable variable _MAIN_PY L509–509
+ _MCP_DISPATCHER variable variable _MCP_DISPATCHER L512–512
+ _MUSEHUB_PKG variable variable _MUSEHUB_PKG L508–508
+ _PROMPTS variable variable _PROMPTS L513–513
+ _ROOT variable variable _ROOT L507–507
+ _SSRF_MODULE variable variable _SSRF_MODULE L27–27
+ _WEBHOOK_MODEL variable variable _WEBHOOK_MODEL L28–28
+ _WIRE_SVC variable variable _WIRE_SVC L514–514
+ AsyncClient import import AsyncClient L505–505
+ AsyncMock import import AsyncMock L21–21
+ MagicMock import import MagicMock L21–21
+ Path import import Path L20–20
+ annotations import import annotations L14–14
+ ast import import ast L16–16
+ hashlib import import hashlib L17–17 ← moved from tests/test_protocol_introspection.py
+ patch import import patch L21–21
+ pytest import import pytest L23–23
+ re import import re L18–18
+ uuid import import uuid L19–19 ← moved from musehub/db/coord_models.py
~ tests/test_wire_oc_server.py .py 1 symbol added, 2 symbols modified
+ fake_id import import fake_id L20–20
~ tests/test_wire_push_stream.py .py 1 symbol added, 3 symbols modified
~ tests/test_wire_snapshot_delta.py .py 7 symbols added, 10 symbols modified
+ _OBJ_9 variable variable _OBJ_9 L24–24
+ _OBJ_F variable variable _OBJ_F L23–23
+ _SNAP_0 variable variable _SNAP_0 L22–22
+ _SNAP_A variable variable _SNAP_A L19–19
+ _SNAP_B variable variable _SNAP_B L20–20
+ _SNAP_C variable variable _SNAP_C L21–21
+ fake_id import import fake_id L16–16

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:de2f3000147eb23e3ef8a8aa2a04edebe09ebd437a014670993a543691891fe2 --body "your comment"