matlab-proxy 0.26.0__tar.gz → 0.27.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of matlab-proxy might be problematic. Click here for more details.
- matlab_proxy-0.27.0/.gitignore +16 -0
- {matlab_proxy-0.26.0/matlab_proxy.egg-info → matlab_proxy-0.27.0}/PKG-INFO +37 -26
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/index.jsx +7 -5
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/selectors/index.js +17 -3
- matlab_proxy-0.27.0/hatch_build.py +73 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/app.py +13 -15
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/app_state.py +8 -2
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/default_configuration.py +2 -2
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/settings.py +3 -2
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/list_servers.py +2 -2
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/environment_variables.py +5 -0
- matlab_proxy-0.27.0/matlab_proxy/util/mwi/session_name.py +28 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/validators.py +2 -4
- matlab_proxy-0.27.0/matlab_proxy_manager/README.md +85 -0
- matlab_proxy-0.27.0/matlab_proxy_manager/lib/README.md +53 -0
- matlab_proxy-0.27.0/matlab_proxy_manager/storage/README.md +54 -0
- matlab_proxy-0.27.0/matlab_proxy_manager/web/README.md +37 -0
- matlab_proxy-0.27.0/pyproject.toml +106 -0
- matlab_proxy-0.27.0/tests/README.md +83 -0
- matlab_proxy-0.27.0/tests/integration/pytest.ini +16 -0
- matlab_proxy-0.27.0/tests/matlab-tests/TestEvaluateUserMatlabCodeScript.m +85 -0
- matlab_proxy-0.27.0/tests/unit/__init__.py +1 -0
- matlab_proxy-0.27.0/tests/unit/fixtures/fixture_auth.py +19 -0
- matlab_proxy-0.27.0/tests/unit/mocks/mock_client.py +42 -0
- matlab_proxy-0.27.0/tests/unit/proxy-manager/lib/test_api.py +311 -0
- matlab_proxy-0.27.0/tests/unit/proxy-manager/storage/test_file_repository.py +152 -0
- matlab_proxy-0.27.0/tests/unit/proxy-manager/storage/test_server.py +237 -0
- matlab_proxy-0.27.0/tests/unit/proxy-manager/web/test_app.py +687 -0
- matlab_proxy-0.27.0/tests/unit/proxy-manager/web/test_monitor.py +120 -0
- matlab_proxy-0.27.0/tests/unit/proxy-manager/web/test_watcher.py +69 -0
- matlab_proxy-0.27.0/tests/unit/pytest.ini +16 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_app.py +24 -3
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_settings.py +29 -0
- matlab_proxy-0.26.0/MANIFEST.in +0 -6
- matlab_proxy-0.26.0/PKG-INFO +0 -249
- matlab_proxy-0.26.0/matlab_proxy.egg-info/SOURCES.txt +0 -190
- matlab_proxy-0.26.0/matlab_proxy.egg-info/dependency_links.txt +0 -1
- matlab_proxy-0.26.0/matlab_proxy.egg-info/entry_points.txt +0 -7
- matlab_proxy-0.26.0/matlab_proxy.egg-info/not-zip-safe +0 -1
- matlab_proxy-0.26.0/matlab_proxy.egg-info/requires.txt +0 -22
- matlab_proxy-0.26.0/matlab_proxy.egg-info/top_level.txt +0 -3
- matlab_proxy-0.26.0/setup.cfg +0 -10
- matlab_proxy-0.26.0/setup.py +0 -129
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/LICENSE.md +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/README.md +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/.eslintrc.json +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/.gitignore +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/README.md +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/eslint.config.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/index.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/index.html +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/package-lock.json +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/package.json +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/public/favicon.ico +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/public/manifest.json +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/public/robots.txt +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/actionCreators/actionCreators.spec.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/actionCreators/index.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/actions/index.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/css/bootstrap.min.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/css/site7.min.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/glyphicons-halflings-regular.eot +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/glyphicons-halflings-regular.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/glyphicons-halflings-regular.ttf +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/glyphicons-halflings-regular.woff +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/glyphicons-halflings-regular.woff2 +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks-eps.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks-eps.ttf +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks-eps.woff +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks-pictograms.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks-pictograms.ttf +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks-pictograms.woff +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks.ttf +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/fonts/mathworks.woff +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/images/bug_reports/workaround.gif +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/images/responsive/global/ico-header-account-hover.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/images/responsive/global/ico-header-account.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/images/responsive/global/ico-header-contact-hover.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/images/responsive/global/ico-header-contact.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/3p/images/responsive/global/ico-sprite.png +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/App.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/App.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/IdleBufferTimeouts.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/App/MATLAB-env-blur.png +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Confirmation/Confirmation.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Confirmation/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/Controls.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/Controls.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/feedback.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/help.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/restart.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/sign-out.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/start.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/stop.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Controls/terminate.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/EntitlementSelector/EntitlementSelector.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/EntitlementSelector/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Error/Error.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Error/Error.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Error/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Help/Help.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Help/Help.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Help/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Information/Information.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Information/Information.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Information/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/ExistingLicense.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/ExistingLicense.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/LicenseGatherer.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/LicensingGatherer.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/MHLM.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/NLM.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/LicensingGatherer/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/MatlabJsd/MatlabJsd.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/MatlabJsd/MatlabJsd.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/MatlabJsd/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Overlay/Overlay.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Overlay/Overlay.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/Overlay/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/OverlayTrigger.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/OverlayTrigger.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/ResizeOverlayTrigger.spec.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/arrow.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/gripper.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/trigger-error.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/OverlayTrigger/trigger-ok.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/ShutdownWarning/ShutdownWarning.css +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/components/ShutdownWarning/index.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/constants.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/main.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/reducers/index.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/reducers/reducers.spec.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/selectors/selectors.spec.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/setupTests.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/test/utils/react-test.jsx +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/test/utils/responses.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/src/test/utils/state.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/gui/vite.config.js +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/constants.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/devel.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/icons/matlab.svg +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/matlab/evaluateUserMatlabCode.m +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/matlab/startup.m +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/cookie_jar.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/event_loop.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mw.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/custom_http_headers.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/download.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/embedded_connector/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/embedded_connector/helpers.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/embedded_connector/request.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/exceptions.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/logger.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/mwi/token_auth.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/system.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy/util/windows.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/lib/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/lib/api.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/storage/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/storage/file_repository.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/storage/interface.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/storage/server.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/auth.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/constants.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/environment_variables.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/exceptions.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/helpers.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/utils/logger.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/web/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/web/app.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/web/monitor.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/matlab_proxy_manager/web/watcher.py +0 -0
- {matlab_proxy-0.26.0/tests/unit → matlab_proxy-0.27.0/tests}/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/integration_tests_with_license/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/integration_tests_with_license/conftest.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/integration_tests_with_license/test_http_end_points.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/integration_tests_without_license/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/integration_tests_without_license/conftest.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/integration_tests_without_license/test_matlab_is_down_if_unlicensed.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/utils/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/utils/integration_tests_utils.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/integration/utils/licensing.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/conftest.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_app_state.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_constants.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_ddux.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_devel.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/test_non_dev_mode.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/embedded_connector/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/embedded_connector/test_helpers.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/embedded_connector/test_request.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/test_custom_http_headers.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/test_download.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/test_logger.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/test_token_auth.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/mwi/test_validators.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/test_cookie_jar.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/test_mw.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/unit/util/test_util.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/utils/__init__.py +0 -0
- {matlab_proxy-0.26.0 → matlab_proxy-0.27.0}/tests/utils/logging_util.py +0 -0
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: matlab-proxy
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.27.0
|
|
4
4
|
Summary: Python® package enables you to launch MATLAB® and access it from a web browser.
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
Project-URL: Homepage, https://github.com/mathworks/matlab-proxy/
|
|
6
|
+
Project-URL: Documentation, https://github.com/mathworks/matlab-proxy/blob/main/README.md
|
|
7
|
+
Project-URL: Issues, https://github.com/mathworks/matlab-proxy/issues
|
|
8
|
+
Author-email: "The MathWorks Inc." <cloud@mathworks.com>
|
|
9
|
+
License-Expression: LicenseRef-MATHWORKS-CLOUD-REFERENCE-ARCHITECTURE-LICENSE
|
|
10
|
+
License-File: LICENSE.md
|
|
11
|
+
Keywords: MATLAB,MATLAB Javascript Desktop,MATLAB Proxy,MATLAB Web Desktop,Proxy,Remote MATLAB Web Access
|
|
10
12
|
Classifier: Intended Audience :: Developers
|
|
11
13
|
Classifier: Natural Language :: English
|
|
12
14
|
Classifier: Programming Language :: Python
|
|
@@ -14,31 +16,40 @@ Classifier: Programming Language :: Python :: 3.8
|
|
|
14
16
|
Classifier: Programming Language :: Python :: 3.9
|
|
15
17
|
Classifier: Programming Language :: Python :: 3.10
|
|
16
18
|
Classifier: Programming Language :: Python :: 3.11
|
|
17
|
-
Requires-Python:
|
|
18
|
-
|
|
19
|
-
License-File: LICENSE.md
|
|
19
|
+
Requires-Python: >=3.8
|
|
20
|
+
Requires-Dist: aiohttp-session[secure]
|
|
20
21
|
Requires-Dist: aiohttp>=3.7.4
|
|
21
|
-
Requires-Dist: aiohttp_session[secure]
|
|
22
22
|
Requires-Dist: importlib-metadata
|
|
23
23
|
Requires-Dist: importlib-resources
|
|
24
24
|
Requires-Dist: psutil
|
|
25
|
-
Requires-Dist: watchdog
|
|
26
25
|
Requires-Dist: requests
|
|
26
|
+
Requires-Dist: watchdog
|
|
27
27
|
Provides-Extra: dev
|
|
28
|
-
Requires-Dist: aiohttp-devtools; extra ==
|
|
29
|
-
Requires-Dist: black; extra ==
|
|
30
|
-
Requires-Dist:
|
|
31
|
-
Requires-Dist: pytest; extra ==
|
|
32
|
-
Requires-Dist: pytest-
|
|
33
|
-
Requires-Dist: pytest-
|
|
34
|
-
Requires-Dist: pytest-
|
|
35
|
-
Requires-Dist: pytest-
|
|
36
|
-
Requires-Dist: pytest-
|
|
37
|
-
Requires-Dist: pytest-
|
|
38
|
-
Requires-Dist:
|
|
39
|
-
Requires-Dist:
|
|
40
|
-
Requires-Dist:
|
|
41
|
-
|
|
28
|
+
Requires-Dist: aiohttp-devtools; extra == 'dev'
|
|
29
|
+
Requires-Dist: black; extra == 'dev'
|
|
30
|
+
Requires-Dist: psutil; extra == 'dev'
|
|
31
|
+
Requires-Dist: pytest; extra == 'dev'
|
|
32
|
+
Requires-Dist: pytest-aiohttp; extra == 'dev'
|
|
33
|
+
Requires-Dist: pytest-asyncio==0.24.0; extra == 'dev'
|
|
34
|
+
Requires-Dist: pytest-cov; extra == 'dev'
|
|
35
|
+
Requires-Dist: pytest-env; extra == 'dev'
|
|
36
|
+
Requires-Dist: pytest-mock; extra == 'dev'
|
|
37
|
+
Requires-Dist: pytest-playwright; extra == 'dev'
|
|
38
|
+
Requires-Dist: pytest-timeout; extra == 'dev'
|
|
39
|
+
Requires-Dist: ruff; extra == 'dev'
|
|
40
|
+
Requires-Dist: urllib3; extra == 'dev'
|
|
41
|
+
Provides-Extra: test
|
|
42
|
+
Requires-Dist: psutil; extra == 'test'
|
|
43
|
+
Requires-Dist: pytest; extra == 'test'
|
|
44
|
+
Requires-Dist: pytest-aiohttp; extra == 'test'
|
|
45
|
+
Requires-Dist: pytest-asyncio==0.24.0; extra == 'test'
|
|
46
|
+
Requires-Dist: pytest-cov; extra == 'test'
|
|
47
|
+
Requires-Dist: pytest-env; extra == 'test'
|
|
48
|
+
Requires-Dist: pytest-mock; extra == 'test'
|
|
49
|
+
Requires-Dist: pytest-playwright; extra == 'test'
|
|
50
|
+
Requires-Dist: pytest-timeout; extra == 'test'
|
|
51
|
+
Requires-Dist: urllib3; extra == 'test'
|
|
52
|
+
Description-Content-Type: text/markdown
|
|
42
53
|
|
|
43
54
|
# MATLAB Proxy
|
|
44
55
|
[](https://github.com/mathworks/matlab-proxy/actions) [](https://pypi.python.org/pypi/matlab-proxy) [](https://codecov.io/gh/mathworks/matlab-proxy) [](https://pepy.tech/project/matlab-proxy)
|
|
@@ -40,6 +40,7 @@ import {
|
|
|
40
40
|
selectMatlabStarting,
|
|
41
41
|
selectIsIdleTimeoutEnabled,
|
|
42
42
|
selectMatlabStopping,
|
|
43
|
+
selectBrowserTitle,
|
|
43
44
|
selectIntegrationName
|
|
44
45
|
} from '../../selectors';
|
|
45
46
|
|
|
@@ -54,7 +55,7 @@ import blurredBackground from './MATLAB-env-blur.png';
|
|
|
54
55
|
import EntitlementSelector from '../EntitlementSelector';
|
|
55
56
|
import { BUFFER_TIMEOUT_DURATION, MWI_AUTH_TOKEN_NAME_FOR_HTTP } from '../../constants';
|
|
56
57
|
|
|
57
|
-
function App
|
|
58
|
+
function App() {
|
|
58
59
|
const dispatch = useDispatch();
|
|
59
60
|
|
|
60
61
|
const overlayVisible = useSelector(selectOverlayVisible);
|
|
@@ -76,6 +77,7 @@ function App () {
|
|
|
76
77
|
const isConcurrencyEnabled = useSelector(selectIsConcurrencyEnabled);
|
|
77
78
|
const wasEverActive = useSelector(selectWasEverActive);
|
|
78
79
|
const integrationName = useSelector(selectIntegrationName);
|
|
80
|
+
const browserTitle = useSelector(selectBrowserTitle);
|
|
79
81
|
|
|
80
82
|
// Timeout duration is specified in seconds, but useTimeoutFn accepts timeout values in ms.
|
|
81
83
|
const idleTimeoutDurationInMS = useSelector(selectIdleTimeoutDurationInMS);
|
|
@@ -93,7 +95,7 @@ function App () {
|
|
|
93
95
|
|
|
94
96
|
|
|
95
97
|
// callback that will fire once the IDLE timer expires
|
|
96
|
-
function terminationFn
|
|
98
|
+
function terminationFn() {
|
|
97
99
|
// Reset the timer if MATLAB is either starting or stopping or is busy
|
|
98
100
|
if (isMatlabStarting || isMatlabStopping || isMatlabBusy) {
|
|
99
101
|
idleTimerReset();
|
|
@@ -303,7 +305,7 @@ function App () {
|
|
|
303
305
|
if (hasFetchedEnvConfig) {
|
|
304
306
|
const queryParams = parseQueryParams(window.location);
|
|
305
307
|
const token = queryParams.get(MWI_AUTH_TOKEN_NAME_FOR_HTTP);
|
|
306
|
-
|
|
308
|
+
document.title = `${browserTitle}`;
|
|
307
309
|
if (token) {
|
|
308
310
|
dispatch(updateAuthStatus(token));
|
|
309
311
|
}
|
|
@@ -331,7 +333,7 @@ function App () {
|
|
|
331
333
|
overlayContent = <ShutdownWarning
|
|
332
334
|
bufferTimeout={BUFFER_TIMEOUT_DURATION}
|
|
333
335
|
resumeCallback={() => {
|
|
334
|
-
|
|
336
|
+
// Restart IDLE timer
|
|
335
337
|
idleTimerReset();
|
|
336
338
|
setIdleTimerHasExpired(false);
|
|
337
339
|
|
|
@@ -386,7 +388,7 @@ function App () {
|
|
|
386
388
|
if (matlabUp) {
|
|
387
389
|
matlabJsd = (!authEnabled || isAuthenticated)
|
|
388
390
|
? (<MatlabJsd handleUserInteraction={handleUserInteraction} url={matlabUrl} iFrameRef={MatlabJsdIframeRef} shouldListenForEvents={shouldListenForEvents} />)
|
|
389
|
-
: <img style={{ objectFit: 'fill' }}src={blurredBackground} alt='Blurred MATLAB environment'/>;
|
|
391
|
+
: <img style={{ objectFit: 'fill' }} src={blurredBackground} alt='Blurred MATLAB environment' />;
|
|
390
392
|
}
|
|
391
393
|
|
|
392
394
|
const overlayTrigger = overlayVisible
|
|
@@ -260,9 +260,23 @@ export const selectIsIdleTimeoutEnabled = createSelector(
|
|
|
260
260
|
export const selectIdleTimeoutDurationInMS = createSelector(
|
|
261
261
|
selectIsIdleTimeoutEnabled,
|
|
262
262
|
selectIdleTimeoutDuration,
|
|
263
|
-
(isTimeoutEnabled, idleTimeoutDuration) => {
|
|
264
|
-
|
|
265
|
-
|
|
263
|
+
(isTimeoutEnabled, idleTimeoutDuration) => {
|
|
264
|
+
return isTimeoutEnabled
|
|
265
|
+
? idleTimeoutDuration * 1000
|
|
266
|
+
: undefined;
|
|
267
|
+
}
|
|
268
|
+
);
|
|
269
|
+
|
|
270
|
+
export const selectBrowserTitle = createSelector(
|
|
271
|
+
selectHasFetchedEnvConfig,
|
|
272
|
+
selectEnvConfig,
|
|
273
|
+
(hasFetchedEnvConfig, envConfig) => {
|
|
274
|
+
if (hasFetchedEnvConfig) {
|
|
275
|
+
return envConfig.browserTitle;
|
|
276
|
+
} else {
|
|
277
|
+
return 'MATLAB';
|
|
278
|
+
}
|
|
279
|
+
}
|
|
266
280
|
);
|
|
267
281
|
|
|
268
282
|
export const selectIntegrationName = createSelector(
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Copyright 2025 The MathWorks, Inc.
|
|
2
|
+
|
|
3
|
+
import os
|
|
4
|
+
import subprocess
|
|
5
|
+
from pathlib import Path
|
|
6
|
+
from shutil import which, copytree
|
|
7
|
+
from typing import Any, Dict
|
|
8
|
+
|
|
9
|
+
from hatchling.builders.hooks.plugin.interface import BuildHookInterface
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class CustomBuildHook(BuildHookInterface):
|
|
13
|
+
# Identifier that connects this Python hook class to pyproject.toml configuration
|
|
14
|
+
PLUGIN_NAME = "custom"
|
|
15
|
+
|
|
16
|
+
def initialize(self, version: str, build_data: Dict[str, Any]) -> None:
|
|
17
|
+
"""Run npm install and build, then copy files to package."""
|
|
18
|
+
|
|
19
|
+
# Ensure npm is present
|
|
20
|
+
npm_path = which("npm")
|
|
21
|
+
if not npm_path:
|
|
22
|
+
raise Exception(
|
|
23
|
+
"npm must be installed and on the path during package build!"
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
npm_install = [npm_path, "install"]
|
|
27
|
+
npm_build = [npm_path, "run", "build"]
|
|
28
|
+
|
|
29
|
+
pwd = Path.cwd()
|
|
30
|
+
gui_path = pwd / "gui"
|
|
31
|
+
gui_build_path = gui_path / "build"
|
|
32
|
+
|
|
33
|
+
if not gui_path.exists():
|
|
34
|
+
raise Exception(f"GUI directory not found: {gui_path}")
|
|
35
|
+
|
|
36
|
+
# Cleanup the build folder to ensure latest artifacts are generated
|
|
37
|
+
if gui_build_path.exists():
|
|
38
|
+
import shutil
|
|
39
|
+
|
|
40
|
+
shutil.rmtree(gui_build_path)
|
|
41
|
+
|
|
42
|
+
# Change to directory where GUI files are present
|
|
43
|
+
original_cwd = str(pwd)
|
|
44
|
+
os.chdir(gui_path)
|
|
45
|
+
|
|
46
|
+
try:
|
|
47
|
+
# Install dependencies and build GUI files
|
|
48
|
+
subprocess.run(npm_install, check=True)
|
|
49
|
+
subprocess.run(npm_build, check=True)
|
|
50
|
+
finally:
|
|
51
|
+
os.chdir(original_cwd)
|
|
52
|
+
|
|
53
|
+
if not gui_build_path.exists():
|
|
54
|
+
raise Exception(f"GUI build directory not found: {gui_build_path}")
|
|
55
|
+
|
|
56
|
+
# Copy built files to a temporary location that will be included in wheel
|
|
57
|
+
temp_gui_path = pwd / "matlab_proxy" / "gui"
|
|
58
|
+
temp_gui_path.mkdir(parents=True, exist_ok=True)
|
|
59
|
+
|
|
60
|
+
# Cleanup pre-existing gui files
|
|
61
|
+
if temp_gui_path.exists():
|
|
62
|
+
import shutil
|
|
63
|
+
|
|
64
|
+
shutil.rmtree(temp_gui_path)
|
|
65
|
+
|
|
66
|
+
copytree(gui_build_path, temp_gui_path)
|
|
67
|
+
|
|
68
|
+
# Create __init__.py files to make directories into Python modules
|
|
69
|
+
(temp_gui_path / "__init__.py").touch(exist_ok=True)
|
|
70
|
+
for root, dirs, _ in os.walk(temp_gui_path):
|
|
71
|
+
for directory in dirs:
|
|
72
|
+
(Path(root) / directory / "__init__.py").touch(exist_ok=True)
|
|
73
|
+
print("Build hook step completed!")
|
|
@@ -209,6 +209,8 @@ async def get_env_config(req):
|
|
|
209
209
|
"supportedVersions": constants.SUPPORTED_MATLAB_VERSIONS,
|
|
210
210
|
}
|
|
211
211
|
|
|
212
|
+
config["browserTitle"] = state.settings["browser_title"]
|
|
213
|
+
|
|
212
214
|
# Send timeout duration for the idle timer as part of the response
|
|
213
215
|
config["idleTimeoutDuration"] = state.settings["mwi_idle_timeout"]
|
|
214
216
|
|
|
@@ -497,15 +499,11 @@ def make_static_route_table(app):
|
|
|
497
499
|
Returns:
|
|
498
500
|
Dict: Containing information about the static files and header information.
|
|
499
501
|
"""
|
|
500
|
-
import importlib_resources
|
|
501
|
-
|
|
502
|
-
from matlab_proxy import gui
|
|
503
|
-
from matlab_proxy.gui import static
|
|
504
|
-
from matlab_proxy.gui.static import
|
|
505
|
-
css, # noqa: F401
|
|
506
|
-
js, # noqa: F401
|
|
507
|
-
media, # noqa: F401
|
|
508
|
-
)
|
|
502
|
+
import importlib_resources as resources
|
|
503
|
+
|
|
504
|
+
from matlab_proxy import gui
|
|
505
|
+
from matlab_proxy.gui import static
|
|
506
|
+
from matlab_proxy.gui.static import css, js, media
|
|
509
507
|
|
|
510
508
|
base_url = app["settings"]["base_url"]
|
|
511
509
|
|
|
@@ -513,14 +511,14 @@ def make_static_route_table(app):
|
|
|
513
511
|
|
|
514
512
|
for mod, parent in [
|
|
515
513
|
(gui.__name__, ""),
|
|
516
|
-
(
|
|
517
|
-
(
|
|
518
|
-
(
|
|
519
|
-
(
|
|
514
|
+
(static.__name__, "/static"),
|
|
515
|
+
(css.__name__, "/static/css"),
|
|
516
|
+
(js.__name__, "/static/js"),
|
|
517
|
+
(media.__name__, "/static/media"),
|
|
520
518
|
]:
|
|
521
|
-
for entry in
|
|
519
|
+
for entry in resources.files(mod).iterdir():
|
|
522
520
|
name = entry.name
|
|
523
|
-
if not
|
|
521
|
+
if not resources.files(mod).joinpath(name).is_dir():
|
|
524
522
|
if name != "__init__.py":
|
|
525
523
|
# Special case for manifest.json
|
|
526
524
|
if "manifest.json" in name:
|
|
@@ -896,8 +896,14 @@ class AppState:
|
|
|
896
896
|
|
|
897
897
|
mwi_server_info_file = mwi_logs_dir / "mwi_server.info"
|
|
898
898
|
mwi_auth_token_str = token_auth.get_mwi_auth_token_access_str(self.settings)
|
|
899
|
-
with open(mwi_server_info_file, "w") as fh:
|
|
900
|
-
fh.write(
|
|
899
|
+
with open(mwi_server_info_file, "w", encoding="utf-8") as fh:
|
|
900
|
+
fh.write(
|
|
901
|
+
self.settings["mwi_server_url"]
|
|
902
|
+
+ mwi_auth_token_str
|
|
903
|
+
+ "\n"
|
|
904
|
+
+ self.settings["browser_title"]
|
|
905
|
+
+ "\n"
|
|
906
|
+
)
|
|
901
907
|
self.mwi_server_session_files["mwi_server_info_file"] = mwi_server_info_file
|
|
902
908
|
logger.debug(f"Server info stored into: {mwi_server_info_file}")
|
|
903
909
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright 2020-
|
|
1
|
+
# Copyright 2020-2025 The MathWorks, Inc.
|
|
2
2
|
from enum import Enum
|
|
3
3
|
from typing import List
|
|
4
4
|
|
|
@@ -45,7 +45,7 @@ def get_required_config() -> List[str]:
|
|
|
45
45
|
list: A list of strings representing the required
|
|
46
46
|
configuration keys.
|
|
47
47
|
"""
|
|
48
|
-
required_keys: List[
|
|
48
|
+
required_keys: List[ConfigKeys] = [
|
|
49
49
|
ConfigKeys.DOC_URL,
|
|
50
50
|
ConfigKeys.EXT_NAME,
|
|
51
51
|
ConfigKeys.EXT_NAME_DESC,
|
|
@@ -21,7 +21,7 @@ from matlab_proxy.constants import MWI_AUTH_TOKEN_NAME_FOR_HTTP
|
|
|
21
21
|
from matlab_proxy.util import mwi, system
|
|
22
22
|
from matlab_proxy.util.cookie_jar import HttpOnlyCookieJar
|
|
23
23
|
from matlab_proxy.util.mwi import environment_variables as mwi_env
|
|
24
|
-
from matlab_proxy.util.mwi import token_auth
|
|
24
|
+
from matlab_proxy.util.mwi import token_auth, session_name
|
|
25
25
|
from matlab_proxy.util.mwi.exceptions import (
|
|
26
26
|
FatalError,
|
|
27
27
|
MatlabInstallError,
|
|
@@ -222,6 +222,7 @@ def get_dev_settings(config):
|
|
|
222
222
|
"is_windowmanager_available": False,
|
|
223
223
|
"mwi_idle_timeout": None,
|
|
224
224
|
"cookie_jar": _get_cookie_jar(),
|
|
225
|
+
"browser_title": session_name.get_browser_title("R2020b"),
|
|
225
226
|
}
|
|
226
227
|
|
|
227
228
|
|
|
@@ -324,7 +325,6 @@ def get_server_settings(config_name):
|
|
|
324
325
|
)
|
|
325
326
|
|
|
326
327
|
cookie_jar = _get_cookie_jar()
|
|
327
|
-
|
|
328
328
|
return {
|
|
329
329
|
"create_xvfb_cmd": create_xvfb_cmd,
|
|
330
330
|
"base_url": mwi.validators.validate_base_url(
|
|
@@ -406,6 +406,7 @@ def get_matlab_settings():
|
|
|
406
406
|
**mw_licensing_urls,
|
|
407
407
|
"nlm_conn_str": nlm_conn_str,
|
|
408
408
|
"has_custom_code_to_execute": has_custom_code_to_execute,
|
|
409
|
+
"browser_title": session_name.get_browser_title(matlab_version),
|
|
409
410
|
}
|
|
410
411
|
|
|
411
412
|
|
|
@@ -31,8 +31,8 @@ def print_server_info():
|
|
|
31
31
|
for server in search_results:
|
|
32
32
|
server_number += 1
|
|
33
33
|
with open(server) as f:
|
|
34
|
-
server_info = f.
|
|
35
|
-
print_output += str(server_number) + ". " + str(server_info)
|
|
34
|
+
server_info = f.readline().strip()
|
|
35
|
+
print_output += str(server_number) + ". " + str(server_info) + "\n"
|
|
36
36
|
|
|
37
37
|
print_output += str(
|
|
38
38
|
mwi_util.prettify(
|
|
@@ -172,6 +172,11 @@ def get_env_name_shutdown_on_idle_timeout():
|
|
|
172
172
|
return "MWI_SHUTDOWN_ON_IDLE_TIMEOUT"
|
|
173
173
|
|
|
174
174
|
|
|
175
|
+
def get_env_name_session_name():
|
|
176
|
+
"""User specified session name for the MATLAB Proxy instance, used to set the browser title."""
|
|
177
|
+
return "MWI_SESSION_NAME"
|
|
178
|
+
|
|
179
|
+
|
|
175
180
|
class Experimental:
|
|
176
181
|
"""This class houses functions which are undocumented APIs and Environment variables.
|
|
177
182
|
Note: Never add any state to this class. Its only intended for use as an abstraction layer
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Copyright 2025 The MathWorks, Inc.
|
|
2
|
+
"""This file provides functions to set a session name for the MATLAB Proxy instance."""
|
|
3
|
+
|
|
4
|
+
import os
|
|
5
|
+
from matlab_proxy.util.mwi import environment_variables as mwi_env
|
|
6
|
+
from matlab_proxy.util.mwi import logger as mwi_logger
|
|
7
|
+
|
|
8
|
+
logger = mwi_logger.get()
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
def _get_session_name():
|
|
12
|
+
"""Get the session name for the MATLAB Proxy instance.
|
|
13
|
+
|
|
14
|
+
Returns:
|
|
15
|
+
str: returns the user-defined session name if set, otherwise returns None.
|
|
16
|
+
"""
|
|
17
|
+
return os.getenv(mwi_env.get_env_name_session_name(), None)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
def get_browser_title(matlab_version) -> str:
|
|
21
|
+
"""Get the browser title for the MATLAB Proxy instance."""
|
|
22
|
+
|
|
23
|
+
browser_title = "MATLAB " + (matlab_version or "")
|
|
24
|
+
session_name = _get_session_name()
|
|
25
|
+
if session_name:
|
|
26
|
+
browser_title = session_name + " - " + browser_title
|
|
27
|
+
logger.info("Session Name set to : %s", session_name)
|
|
28
|
+
return browser_title
|
|
@@ -214,11 +214,9 @@ def __get_configs():
|
|
|
214
214
|
Dict: Contains all the values present in 'matlab_web_desktop_configs' entry_point from all the packages
|
|
215
215
|
installed in the current environment.
|
|
216
216
|
"""
|
|
217
|
-
import importlib_metadata
|
|
217
|
+
import importlib_metadata as metadata
|
|
218
218
|
|
|
219
|
-
matlab_proxy_eps =
|
|
220
|
-
group=matlab_proxy.get_entrypoint_name()
|
|
221
|
-
)
|
|
219
|
+
matlab_proxy_eps = metadata.entry_points(group=matlab_proxy.get_entrypoint_name())
|
|
222
220
|
configs = {}
|
|
223
221
|
for entry_point in matlab_proxy_eps:
|
|
224
222
|
configs[entry_point.name.lower()] = entry_point.load()
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# MATLAB Proxy Manager
|
|
2
|
+
|
|
3
|
+
----
|
|
4
|
+
This README is intended for MathWorks® developers only.
|
|
5
|
+
`matlab-proxy-manager` is part of the `matlab-proxy` package and it helps in managing the lifecycle and proxying of MATLAB proxy processes.
|
|
6
|
+
|
|
7
|
+
It provides a seamless integration with Jupyter environments, allowing MATLAB to be accessed and controlled via a proxy.
|
|
8
|
+
|
|
9
|
+
Upon installation, this package introduces an executable `matlab-proxy-manager-app`, which is utilized by the Jupyter Server Proxy to initiate `matlab-proxy-manager`.
|
|
10
|
+
|
|
11
|
+
----
|
|
12
|
+
|
|
13
|
+
**Table of Contents**
|
|
14
|
+
- [Project Structure](#structure)
|
|
15
|
+
- [Installation](#installation)
|
|
16
|
+
- [PyPI](#pypi)
|
|
17
|
+
- [Building From Sources](#building-from-sources)
|
|
18
|
+
- [Usage](#usage)
|
|
19
|
+
- [Security](#security)
|
|
20
|
+
|
|
21
|
+
## Structure
|
|
22
|
+
`matlab-proxy-manager` is organized into several key sub-folders:
|
|
23
|
+
|
|
24
|
+
1. lib:
|
|
25
|
+
|
|
26
|
+
* This directory contains the library APIs that facilitate the invocation of MATLAB proxy processes. It supports API calls, enabling the MATLAB Kernel to manage proxy instances effectively. For detailed information, refer to the README within the lib folder.
|
|
27
|
+
|
|
28
|
+
2. storage:
|
|
29
|
+
* The file system serves as the source of truth for `matlab-proxy-manager`, storing metadata about each MATLAB proxy server in dedicated files. A new file is generated whenever a proxy instance is launched and is removed upon termination of the instance or deletion of the Kernel that initiated it.
|
|
30
|
+
|
|
31
|
+
3. web:
|
|
32
|
+
* This component handles proxy workflows through HTTP/WebSocket requests, which are part of the executable process spawned by clients using the `matlab-proxy-manager-app`. For specific requirements and constraints, consult the README located in the web folder.
|
|
33
|
+
|
|
34
|
+
4. utils:
|
|
35
|
+
* A collection of helper functions utilized across various parts of the project, ensuring modularity and code reuse.
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
### PyPI
|
|
40
|
+
`matlab-proxy-manager` is included in the `matlab-proxy` repository and can be easily installed from the Python Package Index:
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
python -m pip install matlab-proxy
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### Building From Sources
|
|
47
|
+
Building from sources requires Node.js® version 16 or higher. [Click here to install Node.js](https://nodejs.org/en/)
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
git clone https://github.com/mathworks/matlab-proxy.git
|
|
51
|
+
|
|
52
|
+
cd matlab-proxy
|
|
53
|
+
|
|
54
|
+
python -m pip install .
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Installing the package creates an executable called `matlab-proxy-app`, which is placed onto your system PATH by `pip`, usually in: `$HOME/.local/bin/`
|
|
58
|
+
```bash
|
|
59
|
+
# Verify its presence on the PATH
|
|
60
|
+
which matlab-proxy-manager-app
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
## Usage
|
|
64
|
+
`matlab-proxy-manager` can be deployed in two modes:
|
|
65
|
+
|
|
66
|
+
1. Library Mode: Import the relevant module within your client code to invoke public APIs directly.
|
|
67
|
+
|
|
68
|
+
Example:
|
|
69
|
+
|
|
70
|
+
```python
|
|
71
|
+
import matlab_proxy_manager.lib.api as mpm_lib
|
|
72
|
+
response = await mpm_lib.start_matlab_proxy_for_kernel(...)
|
|
73
|
+
await mpm_lib.shutdown(...)
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
2. Process Mode: This mode is primarily managed by Jupyter-Server-Proxy for proxy workflows involving web-based MATLAB desktop access.
|
|
77
|
+
|
|
78
|
+
## Security
|
|
79
|
+
Security is paramount in matlab-proxy-manager. Communication between the Kernel, proxy manager, and Jupyter Server Proxy is secured using authentication tokens. These tokens are mandatory for API invocations and proxy workflows. They are passed via environment variables when the proxy manager is initiated by the Jupyter Server Proxy and are included in the arguments during Kernel API calls.
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
Copyright 2024 The MathWorks, Inc.
|
|
84
|
+
|
|
85
|
+
---
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# MATLAB Proxy Manager - Library
|
|
2
|
+
|
|
3
|
+
This README is intended for MathWorks® developers only.
|
|
4
|
+
`matlab-proxy-manager` module is designed to be flexible and robust, supporting both direct library calls and process-based workflows. The lib folder contains the code blocks providing the core library APIs that facilitate the management of MATLAB proxy instances.
|
|
5
|
+
|
|
6
|
+
# Key Features
|
|
7
|
+
## API Invocation:
|
|
8
|
+
|
|
9
|
+
The lib module allows for the invocation of MATLAB proxy processes through a well-defined set of APIs. These APIs are designed to be intuitive and easy to integrate into existing workflows, enabling developers to start, stop, and manage MATLAB proxy instances programmatically.
|
|
10
|
+
|
|
11
|
+
## Integration with MATLAB Kernel:
|
|
12
|
+
|
|
13
|
+
The APIs in the lib directory are used by the MATLAB Kernel to manage the lifecycle of MATLAB proxy instances. This includes starting new instances and shutting them down when they are no longer needed.
|
|
14
|
+
|
|
15
|
+
## Error Handling and Logging:
|
|
16
|
+
|
|
17
|
+
Comprehensive error handling mechanisms are in place to ensure that any issues encountered during the management of proxy instances are logged and reported. This aids in troubleshooting and ensures the reliability of the system.
|
|
18
|
+
|
|
19
|
+
Users are required to set `MWI_MPM_LOG_LEVEL` environment variable to their desired log level (`INFO`, `DEBUG` etc.) to enable logging in `matlab-proxy-manager`.
|
|
20
|
+
|
|
21
|
+
# Usage
|
|
22
|
+
To use the lib APIs, you can import the relevant module in your Python code and invoke the provided functions. Here’s a basic example of how you might start and stop a MATLAB proxy instance:
|
|
23
|
+
|
|
24
|
+
```python
|
|
25
|
+
|
|
26
|
+
import matlab_proxy_manager.lib.api as mpm_lib
|
|
27
|
+
|
|
28
|
+
# Start a MATLAB proxy instance
|
|
29
|
+
response = await mpm_lib.start_matlab_proxy_for_kernel(
|
|
30
|
+
caller_id=self.kernel_id,
|
|
31
|
+
parent_id=self.parent_pid,
|
|
32
|
+
is_shared_matlab=True,
|
|
33
|
+
)
|
|
34
|
+
return (
|
|
35
|
+
response.get("absolute_url"),
|
|
36
|
+
response.get("mwi_base_url"),
|
|
37
|
+
response.get("headers"),
|
|
38
|
+
response.get("mpm_auth_token"),
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
# Perform operations with the MATLAB instance...
|
|
42
|
+
|
|
43
|
+
# Shut down the MATLAB proxy instance
|
|
44
|
+
await mpm_lib.shutdown(
|
|
45
|
+
self.parent_pid, self.kernel_id, self.mpm_auth_token
|
|
46
|
+
)
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
---
|
|
50
|
+
|
|
51
|
+
Copyright 2024 The MathWorks, Inc.
|
|
52
|
+
|
|
53
|
+
---
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# MATLAB Proxy Manager - Storage
|
|
2
|
+
|
|
3
|
+
This README is intended for MathWorks® developers only.
|
|
4
|
+
The storage module is a critical part of the `matlab-proxy-manager`, responsible for managing the persistence of metadata related to MATLAB proxy instances. It employs a repository pattern to provide a clean and consistent interface for performing CRD (Create, Read, Delete) operations on the file system.
|
|
5
|
+
|
|
6
|
+
## Key Features
|
|
7
|
+
|
|
8
|
+
### Repository Pattern:
|
|
9
|
+
|
|
10
|
+
The storage module is designed using the repository pattern, which abstracts the data layer and provides a straightforward API for interacting with stored metadata. This pattern ensures that the underlying data storage mechanism can be modified or replaced with minimal impact on the rest of the application.
|
|
11
|
+
|
|
12
|
+
### File System-Based Storage:
|
|
13
|
+
|
|
14
|
+
Currently, the storage operations are performed directly on the file system. Each MATLAB proxy instance's metadata is stored in a separate file, making it easy to manage and access individual instances.
|
|
15
|
+
|
|
16
|
+
### CRD Operations:
|
|
17
|
+
|
|
18
|
+
The storage module provides a set of APIs to perform CRD operations:
|
|
19
|
+
|
|
20
|
+
1. add(...): Create a new metadata file for a MATLAB proxy instance.
|
|
21
|
+
2. get(...): Retrieve metadata for a specific instance.
|
|
22
|
+
3. get_all(): Retrieve metadata for all instances.
|
|
23
|
+
4. delete(...): Remove the metadata file for a specific instance.
|
|
24
|
+
|
|
25
|
+
Usage
|
|
26
|
+
To use the storage APIs, clients can import the relevant module and invoke the provided functions. Here’s an example of how to perform basic CRUD operations:
|
|
27
|
+
|
|
28
|
+
```python
|
|
29
|
+
|
|
30
|
+
from matlab_proxy_manager.storage.file_repository import FileRepository
|
|
31
|
+
|
|
32
|
+
storage = FileRepository(data_dir)
|
|
33
|
+
|
|
34
|
+
# Add a new MATLAB proxy instance metadata
|
|
35
|
+
filename = '1234.info'
|
|
36
|
+
server_process = <instance of ServerProcess class>
|
|
37
|
+
storage.add(server=server_process, filename=filename)
|
|
38
|
+
|
|
39
|
+
# Retrieve metadata for a specific instance
|
|
40
|
+
filename = f"{parent_pid}_{caller_id}"
|
|
41
|
+
full_file_path, server = storage.get(filename)
|
|
42
|
+
|
|
43
|
+
# Retrieve metadata for all instances
|
|
44
|
+
servers = storage.get_all()
|
|
45
|
+
|
|
46
|
+
# Delete metadata for a specific instance
|
|
47
|
+
storage.delete(f"{filename}.info")
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
Copyright 2024 The MathWorks, Inc.
|
|
53
|
+
|
|
54
|
+
---
|