pretext 2.33.3.dev20251221064246__py3-none-any.whl → 2.33.3.dev20251227064414__py3-none-any.whl
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.
- pretext/__init__.py +1 -1
- pretext/core/pretext.py +27 -13
- pretext/resources/core.zip +0 -0
- pretext/resources/pelican.zip +0 -0
- pretext/resources/resource_hash_table.json +9 -9
- pretext/resources/rs_cache.zip +0 -0
- pretext/resources/templates.zip +0 -0
- {pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/METADATA +1 -1
- {pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/RECORD +12 -12
- {pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/LICENSE +0 -0
- {pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/WHEEL +0 -0
- {pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/entry_points.txt +0 -0
pretext/__init__.py
CHANGED
|
@@ -19,7 +19,7 @@ from single_version import get_version
|
|
|
19
19
|
VERSION = get_version("pretext", Path(__file__).parent.parent)
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
CORE_COMMIT = '
|
|
22
|
+
CORE_COMMIT = 'aa22f79b0c98cbe210fba4ec6824ec2ce97bf11e'
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
def activate() -> None:
|
pretext/core/pretext.py
CHANGED
|
@@ -2799,7 +2799,7 @@ def stack_extraction(xml_source, pub_file, stringparams, xmlid_root, dest_dir ):
|
|
|
2799
2799
|
pub_vars = get_publisher_variable_report(xml_source, pub_file, stringparams)
|
|
2800
2800
|
stack_server = get_publisher_variable(pub_vars, 'stack-server')
|
|
2801
2801
|
api_url = urllib.parse.urljoin(stack_server, 'render')
|
|
2802
|
-
log.info(
|
|
2802
|
+
log.info("Using STACK API server at {}".format(api_url))
|
|
2803
2803
|
|
|
2804
2804
|
os.makedirs(dest_dir, exist_ok=True)
|
|
2805
2805
|
msg = 'converting STACK exercises from {} to static forms for placement in {}'
|
|
@@ -2818,21 +2818,35 @@ def stack_extraction(xml_source, pub_file, stringparams, xmlid_root, dest_dir ):
|
|
|
2818
2818
|
|
|
2819
2819
|
log.info("extracting STACK exercises from {}".format(xml_source))
|
|
2820
2820
|
log.info("string parameters passed to extraction stylesheet: {}".format(stringparams) )
|
|
2821
|
-
# place verbatim copies of STACK XML into a temporary directory
|
|
2822
|
-
xsltproc(extraction_xslt, xml_source, None, tmp_dir, stringparams)
|
|
2823
2821
|
|
|
2824
|
-
#
|
|
2825
|
-
|
|
2822
|
+
# Build list of stack/@source into a scratch directory/file
|
|
2823
|
+
tmp_dir = get_temporary_directory()
|
|
2824
|
+
source_filename = os.path.join(tmp_dir, "stack-source.txt")
|
|
2825
|
+
log.debug("STACK source filenames temporarily in {}".format(source_filename))
|
|
2826
|
+
xsltproc(extraction_xslt, xml_source, source_filename, None, stringparams)
|
|
2827
|
+
|
|
2828
|
+
# Course over (source, id) pairs in file created by
|
|
2829
|
+
# extraction stylesheet, converting source STACK files
|
|
2830
|
+
# to PreTeXt files based on id/label. Innermost loop
|
|
2826
2831
|
# is modeled after work provided in
|
|
2827
2832
|
# https://github.com/PreTeXtBook/pretext/pull/2576
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
|
|
2834
|
-
|
|
2835
|
-
|
|
2833
|
+
|
|
2834
|
+
# location of external directory for STACK files
|
|
2835
|
+
_, external_dir = get_managed_directories(xml_source, pub_file)
|
|
2836
|
+
|
|
2837
|
+
with open(source_filename, "r") as source_file:
|
|
2838
|
+
for source in source_file:
|
|
2839
|
+
|
|
2840
|
+
# source is the stack/@source attribute
|
|
2841
|
+
# label is the "assembly-id" used for base filename
|
|
2842
|
+
source, label = source.split()
|
|
2843
|
+
# external directory plus authored @source is STACK question
|
|
2844
|
+
stack_file = os.path.join(external_dir, source)
|
|
2845
|
+
# destination directory, label/id filename, PTX extension is
|
|
2846
|
+
# static version of question, to be melded in by assembly stylesheet
|
|
2847
|
+
pretext_file = os.path.join(dest_dir, label + '.ptx')
|
|
2848
|
+
msg = 'converting STACK question file "{}" to static PreTeXt XML file "{}"'
|
|
2849
|
+
log.debug(msg.format(stack_file, pretext_file))
|
|
2836
2850
|
|
|
2837
2851
|
# Open STACK XML file, send to server, unravel JSON response into
|
|
2838
2852
|
# a text version of the static PreTeXt XML question
|
pretext/resources/core.zip
CHANGED
|
Binary file
|
pretext/resources/pelican.zip
CHANGED
|
Binary file
|
|
@@ -523,14 +523,14 @@
|
|
|
523
523
|
"installPandoc.sh": "a18b850870b5e2d744c99300c0643f12a81eba3e27dfd985927554af2062c967",
|
|
524
524
|
"installSage.sh": "8020b532e1101c77c5681c0dfaff308a36c60e95db6b0f652bf230f7de216cb8"
|
|
525
525
|
},
|
|
526
|
-
"2.33.3.
|
|
527
|
-
"project.ptx": "
|
|
528
|
-
"codechat_config.yaml": "
|
|
529
|
-
".gitignore": "
|
|
530
|
-
"devcontainer.json": "
|
|
531
|
-
"pretext-cli.yml": "
|
|
532
|
-
"pretext-deploy.yml": "
|
|
533
|
-
"installPandoc.sh": "
|
|
534
|
-
"installSage.sh": "
|
|
526
|
+
"2.33.3.dev20251227064414": {
|
|
527
|
+
"project.ptx": "7f55ca3bae8682566bbd86339076a96da3a6b5027cb4c7a8b2c9cac3c864c862",
|
|
528
|
+
"codechat_config.yaml": "588babed2d0101d80cfe02a5ccead7bd7983893ac30431d2653da1d41f2fab65",
|
|
529
|
+
".gitignore": "50317925b357a35e6316de355bd12c6c4d9a4070ce6c9cdc3d52e9a3310bef67",
|
|
530
|
+
"devcontainer.json": "24e4e3dfc5006798628f67b7e99d756ac8e54d9c04c7a3f56744af8562c9e771",
|
|
531
|
+
"pretext-cli.yml": "140d7c4428d7fd1f05e7b338fbc73de2493a37c4916de818a2dc845cea818850",
|
|
532
|
+
"pretext-deploy.yml": "28a7451a806d307bcb769754389bfb8065cdce6327c6f015a93b1c3d2ab20afe",
|
|
533
|
+
"installPandoc.sh": "1281030858e10259fba1a2553055594303ca126d71cf64a7e0809273dde55053",
|
|
534
|
+
"installSage.sh": "35846511b1d377a5a69a6143c17233b117ee415f0ecbbda93bdd63ec82b4593d"
|
|
535
535
|
}
|
|
536
536
|
}
|
pretext/resources/rs_cache.zip
CHANGED
|
Binary file
|
pretext/resources/templates.zip
CHANGED
|
Binary file
|
{pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/RECORD
RENAMED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
pretext/__init__.py,sha256=
|
|
1
|
+
pretext/__init__.py,sha256=luvaeUyDmSp_csVF6fXwshfFGiM4FRZscktQ5tH0Yvc,1453
|
|
2
2
|
pretext/__main__.py,sha256=MSmt_5Xg84uHqzTN38JwgseJK8rsJn_11A8WD99VtEo,61
|
|
3
3
|
pretext/cli.py,sha256=VkDFWViY4Wa8aYdXC4rIHaAEq5-UUuVZR4Pw8mqp1f0,40546
|
|
4
4
|
pretext/codechat.py,sha256=7FCz_TLf8yVSG5doGRvJ0rrpShZEejtlZ3ZyaWJrm9I,6305
|
|
5
5
|
pretext/constants.py,sha256=cKxyUUy0SNX1M41CtJJtBpaHXTrKrZQPLrrbOJpCoU8,6843
|
|
6
6
|
pretext/core/__init__.py,sha256=CmOXWPslsSiVzldc2UXNRug-xL8Ax601zGrp_3VhWxQ,739
|
|
7
7
|
pretext/core/braille_format.py,sha256=ra1zVsyoUSUuGWCtY0VGF0FuEfHQ34oXtJvgKiiImdg,36377
|
|
8
|
-
pretext/core/pretext.py,sha256=
|
|
8
|
+
pretext/core/pretext.py,sha256=51GDW1ERfMZKfq3dMDod8__NWq1AUwlIw-Q4DYxfvl0,273225
|
|
9
9
|
pretext/logger.py,sha256=b58izYIs9xEmVOXd3wvKpQ-AH1mRsGFG2FDjJM_MyOE,1456
|
|
10
10
|
pretext/plastex/Alignment.jinja2s,sha256=AfFPeWxhTo6H6MDWogYTGylWfZed4BX5BgkWLCObBqI,409
|
|
11
11
|
pretext/plastex/Arrays.jinja2s,sha256=MHWFbO7CoYzIRWwg5QH38dhrU20N5x7BxEnzuIQ0rfU,294
|
|
@@ -50,16 +50,16 @@ pretext/project/__init__.py,sha256=Q4Met0dWYgoIA-hma8xiJipbQU48zEeubQJ8-joXOqk,8
|
|
|
50
50
|
pretext/project/generate.py,sha256=Qn79ap89dSHKYhFUw494nkMVCN4qJUQjZBnJOhAbyqQ,9158
|
|
51
51
|
pretext/project/xml.py,sha256=wtaXS2isRG6QlfyfNNccAbFt6Izwm7yxAledwd1Q6AA,3456
|
|
52
52
|
pretext/resources/__init__.py,sha256=1qPohIxCtL1_sUtlAoFrWzhl31l-oFj4RrBBsb3RzQQ,4081
|
|
53
|
-
pretext/resources/core.zip,sha256=
|
|
54
|
-
pretext/resources/pelican.zip,sha256=
|
|
55
|
-
pretext/resources/resource_hash_table.json,sha256=
|
|
56
|
-
pretext/resources/rs_cache.zip,sha256=
|
|
57
|
-
pretext/resources/templates.zip,sha256=
|
|
53
|
+
pretext/resources/core.zip,sha256=agbyIPw62W6lt7zjeW0q6r7GUe6GmhmiX0zHicsPZKI,1757887
|
|
54
|
+
pretext/resources/pelican.zip,sha256=0w1Gb59Pa2KNc352qDME4VxGdK6_x-URlUNzuJMOqUI,15974
|
|
55
|
+
pretext/resources/resource_hash_table.json,sha256=k2c_u_JjDndkVlWzi54gg8hhCht3ApykdtcC1OG0aw0,39814
|
|
56
|
+
pretext/resources/rs_cache.zip,sha256=SrmIWzNvuC4phGikSv0NxodtfqQeNOl9ERQ2S8TdBO0,14940790
|
|
57
|
+
pretext/resources/templates.zip,sha256=Oo_Fqwo_zCLxbtRlzto3j13tIl5zvi3ko9nJBksN3sc,375357
|
|
58
58
|
pretext/server.py,sha256=B90NC6kevNeJNbwtUh3iVxF_BH5tiA4522XsjONsGSc,10800
|
|
59
59
|
pretext/types.py,sha256=Eyyu6xmmCYnKBfvzBZzZMWZMa3yNjZ8NnGmlFGj9p5I,168
|
|
60
60
|
pretext/utils.py,sha256=xAOsqcJo3Z6v3UlRbZeQN9nFWTNdhBpfUZ_BwqJFpio,45029
|
|
61
|
-
pretext-2.33.3.
|
|
62
|
-
pretext-2.33.3.
|
|
63
|
-
pretext-2.33.3.
|
|
64
|
-
pretext-2.33.3.
|
|
65
|
-
pretext-2.33.3.
|
|
61
|
+
pretext-2.33.3.dev20251227064414.dist-info/LICENSE,sha256=ixuiBLtpoK3iv89l7ylKkg9rs2GzF9ukPH7ynZYzK5s,35148
|
|
62
|
+
pretext-2.33.3.dev20251227064414.dist-info/METADATA,sha256=f2YBPAsyieHtRoKG_v6oQ6D2ApYqwy_v919_PTC9fYA,11492
|
|
63
|
+
pretext-2.33.3.dev20251227064414.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
|
64
|
+
pretext-2.33.3.dev20251227064414.dist-info/entry_points.txt,sha256=L-rrQFUIWZhdOdu-XBQ9iuFK3X1cMVOtC-0I7T87II8,44
|
|
65
|
+
pretext-2.33.3.dev20251227064414.dist-info/RECORD,,
|
{pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/LICENSE
RENAMED
|
File without changes
|
{pretext-2.33.3.dev20251221064246.dist-info → pretext-2.33.3.dev20251227064414.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|