Title: The agent keeps a reference to an instrumented function that prevents it from being garbage collected · Issue #317 · getappmap/appmap-python · GitHub
Open Graph Title: The agent keeps a reference to an instrumented function that prevents it from being garbage collected · Issue #317 · getappmap/appmap-python
X Title: The agent keeps a reference to an instrumented function that prevents it from being garbage collected · Issue #317 · getappmap/appmap-python
Description: https://github.com/pallets/flask ============================================================== FAILURES ============================================================== __________________________________________________ test_app_freed_on_...
Open Graph Description: https://github.com/pallets/flask ============================================================== FAILURES ============================================================== _____________________________...
X Description: https://github.com/pallets/flask ============================================================== FAILURES ============================================================== _____________________________...
Opengraph URL: https://github.com/getappmap/appmap-python/issues/317
X: @github
Domain: github.com
IPv4 address: 140.82.113.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"The agent keeps a reference to an instrumented function that prevents it from being garbage collected","articleBody":"https://github.com/pallets/flask\r\n\r\n```\r\n============================================================== FAILURES ==============================================================\r\n__________________________________________________ test_app_freed_on_zero_refcount ___________________________________________________\r\n\r\n @require_cpython_gc\r\n def test_app_freed_on_zero_refcount():\r\n # A Flask instance should not create a reference cycle that prevents CPython\r\n # from freeing it when all external references to it are released (see #3761).\r\n gc.disable()\r\n try:\r\n app = flask.Flask(__name__)\r\n assert app.view_functions[\"static\"]\r\n weak = weakref.ref(app)\r\n assert weak() is not None\r\n del app\r\n> assert weak() is None\r\nE AssertionError: assert \u003cFlask 'test_basic'> is None\r\nE + where \u003cFlask 'test_basic'> = \u003cweakref at 0x11b897b50; to 'Flask' at 0x11bcc5150>()\r\n\r\ntests/test_basic.py:1888: AssertionError\r\n--------------------------------------------------------- Captured log call ----------------------------------------------------------\r\nINFO _appmap.recording:recording.py:77 writing /Users/kgilpin/source/land-of-apps/pallets-flask/tmp/appmap/pytest/test_app_freed_on_zero_refcount.appmap.json\r\n========================================================== warnings summary ==========================================================\r\nvenv/lib/python3.10/site-packages/_pytest/assertion/rewrite.py:274\r\n /Users/kgilpin/source/land-of-apps/pallets-flask/venv/lib/python3.10/site-packages/_pytest/assertion/rewrite.py:274: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: _appmap\r\n self.config.issue_config_time_warning(\r\n\r\nvenv/lib/python3.10/site-packages/_pytest/assertion/rewrite.py:274\r\n /Users/kgilpin/source/land-of-apps/pallets-flask/venv/lib/python3.10/site-packages/_pytest/assertion/rewrite.py:274: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: appmap\r\n self.config.issue_config_time_warning(\r\n\r\ntests/test_basic.py::test_server_name_subdomain\r\n /Users/kgilpin/source/land-of-apps/pallets-flask/venv/lib/python3.10/site-packages/_appmap/instrument.py:92: UserWarning: Current server name 'foo.localhost' doesn't match configured server name 'dev.local'\r\n ret = f.fn(*args, **kwargs)\r\n\r\ntests/test_basic.py::test_subdomain_matching_other_name[False]\r\ntests/test_basic.py::test_subdomain_matching_other_name[True]\r\n /Users/kgilpin/source/land-of-apps/pallets-flask/venv/lib/python3.10/site-packages/_appmap/instrument.py:92: UserWarning: Current server name '127.0.0.1:3000' doesn't match configured server name 'localhost.localdomain:3000'\r\n ret = f.fn(*args, **kwargs)\r\n\r\ntests/test_reqctx.py::test_proper_test_request_context\r\n /Users/kgilpin/source/land-of-apps/pallets-flask/venv/lib/python3.10/site-packages/_appmap/instrument.py:92: UserWarning: Current server name 'localhost' doesn't match configured server name 'localhost.localdomain:5000'\r\n ret = f.fn(*args, **kwargs)\r\n\r\n-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html\r\n====================================================== short test summary info =======================================================\r\nFAILED tests/test_basic.py::test_app_freed_on_zero_refcount - AssertionError: assert \u003cFlask 'test_basic'> is None\r\n================================== 1 failed, 469 passed, 7 skipped, 6 warnings in 85.70s (0:01:25) ===================================\r\n```","author":{"url":"https://github.com/kgilpin","@type":"Person","name":"kgilpin"},"datePublished":"2024-05-24T16:32:56Z","url":"https://github.com/getappmap/appmap-python/issues/317"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:a965a373-59fc-38c2-9f55-42b0adfdeebd |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BE96:31D21B:18DEAAF:20C524C:6B0323C9 |
| html-safe-nonce | ac5d4413ba7bbc310ead373f4c6f1e57acdde2970ae7b6ab6bbb00e79300556f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRTk2OjMxRDIxQjoxOERFQUFGOjIwQzUyNEM6NkIwMzIzQzkiLCJ2aXNpdG9yX2lkIjoiNTk3NjY4Njg1NTIxNzk0NzU5MyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 4e86c00554ed81c40172b8080098d8075ea86047c564ada22b2abd518df8ccb7 |
| hovercard-subject-tag | issue:2315803566 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/getappmap/appmap-python/317/issue_layout |
| twitter:image | https://opengraph.githubassets.com/5c68b30e03a91d3acaf2c5c85d8c7d4d543b4b1adeb294537b3481d61c751799/getappmap/appmap-python/issues/317 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/5c68b30e03a91d3acaf2c5c85d8c7d4d543b4b1adeb294537b3481d61c751799/getappmap/appmap-python/issues/317 |
| og:image:alt | https://github.com/pallets/flask ============================================================== FAILURES ============================================================== _____________________________... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | kgilpin |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/getappmap/appmap-python git https://github.com/getappmap/appmap-python.git |
| octolytics-dimension-user_id | 46610017 |
| octolytics-dimension-user_login | getappmap |
| octolytics-dimension-repository_id | 314785884 |
| octolytics-dimension-repository_nwo | getappmap/appmap-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 314785884 |
| octolytics-dimension-repository_network_root_nwo | getappmap/appmap-python |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width