Project module refactor discussion #458
Replies: 25 comments 49 replies
-
After today's chat in Zoom, I'm tasked to tackle this + refactoring project.py. |
Beta Was this translation helpful? Give feedback.
-
I would like to make another pitch for two additional attributes on target (optional!)
Right now for both Runestone builds as well as working on developing interactive components I have to write additional wrapper scripts around the pretext build command. It would be much faster and more open if we could support those two hooks. For example a prebuild-hook could run
Those are just my use cases... |
Beta Was this translation helpful? Give feedback.
-
I've started working on this, but the Codespaces dev environment is stale and preventing me from testing/linting in the UI, so I'm attacking that instead now. |
Beta Was this translation helpful? Give feedback.
-
I would also like to propose that we include a runestone target by default. There are more and more existing authors that are now wanting to put their books on Runestone. There is no reason for this to be a burden to them when we can provide the basic target or them. Further we can reduce friction for existing authors by asking for and validating their document-id when they set up a new project either with |
Beta Was this translation helpful? Give feedback.
-
One of the things I like about the cli is that I have a consistent way to build all of the pretext books
Put simply, I want to use the cli as a tool in my build chain. I really don't understand the resistance to just adding a target for runestone. Its no more complicated than the latex tags which are included. publishing on runestone is not the first thing that any author is going to do. So focusing on making it easy for them to do everything but publish on runestone seems reasonable. But why not just add the runestone target when you have asked for all this information during the We can easily work together during that init process to try to make the transition to runestone as simple as possible later on. |
Beta Was this translation helpful? Give feedback.
-
@oscarlevin I have a WIP that would benefit from your eyeballs if you can sync up with me sometime today. |
Beta Was this translation helpful? Give feedback.
-
I'm about to have to step away from this for at least the next week, if @oscarlevin wants to move #464 forward. I've been fairly vigilant about testing (but not type checking, see #469, though I've been trying to keep things type safe manually), so https://github.com/PreTeXtBook/pretext-cli/blob/refactor-project/tests/test_project.py is a good reference on what's been implemented. Essentially we have builds and asset generation up and running, but not staging/deployment of sites and/or targets. Due to the redesign, it's just as easy to manage your project dynamically in a Python script as it is to configure it via a I've tried to touch stuff outside
As of now, all the existing tests still pass, so the changes outside of Here's what I know needs to happen:
|
Beta Was this translation helpful? Give feedback.
-
I've pushed some big updates to this. Things to do:
Tests pass, except for the problems listed above. @StevenClontz or @oscarlevin, can you look at / work on this? |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
What do you think @oscarlevin? We're not using |
Beta Was this translation helpful? Give feedback.
-
@oscarlevin knows braille stuff much better. N.B. |
Beta Was this translation helpful? Give feedback.
-
I've fixed what I can -- waiting on input now. |
Beta Was this translation helpful? Give feedback.
-
I must admit I've lost track of the plan for this, so @StevenClontz, can you take stock of where we are and what we need to do to get this folded in? I have time to help finish this off now, but not sure what needs to get done still. |
Beta Was this translation helpful? Give feedback.
-
Sounds good! I'll need to leave around 4:00 PM Central, but I think we can make some good progress! |
Beta Was this translation helpful? Give feedback.
-
It looks like I can be at dropin for the first 30 minutes and hopefully at 3:30 CDT to further sync up.
|
Beta Was this translation helpful? Give feedback.
-
I've made some good progress, but need help at this point. The lastest pushes get almost all tests passing, except a failure involving WebWork conversion, where fails to find the resulting generated WebWork output. I'm not sure how to debug this. |
Beta Was this translation helpful? Give feedback.
-
@oscarlevin, can you help with this? @StevenClontz and I chatted, and we dubbed you the expert :). What we see: on line 205 of the CI output, it looks like spaces are translated to
Any idea why/how? |
Beta Was this translation helpful? Give feedback.
-
Okay, I think I know what the issue is with the test not passing: the other This is a fairly major bug with our 1.7 release, so I'll fix this asap, release a bug fix, and we can merge that into the refactor-project branch. |
Beta Was this translation helpful? Give feedback.
-
Wow, way to go Oscar! That's a tricky bug. Nice! |
Beta Was this translation helpful? Give feedback.
-
FYI here's where, once the refactored project is available in nightlies, I plan to try out the dynamic target editing to run some custom XSL to produce individual slideshows for each section of the TBIL Linear Algebra text: https://github.com/TeamBasedInquiryLearning/linear-algebra/blob/2023-slides/slides/build.py |
Beta Was this translation helpful? Give feedback.
-
Okay, the |
Beta Was this translation helpful? Give feedback.
-
One error had to do with a bug in The other seems related to https://stackoverflow.com/questions/52265120/python-multiprocessing-pool-attributeerror |
Beta Was this translation helpful? Give feedback.
-
Sure! |
Beta Was this translation helpful? Give feedback.
-
project.ptx
(I volunteer to write a converter from<2
)Beta Was this translation helpful? Give feedback.
All reactions