sile-typesetter / cassowary.lua Goto Github PK
View Code? Open in Web Editor NEWA Lua port of the cassowary constraint solver engine
Home Page: https://luarocks.org/modules/simoncozens/cassowary
License: Apache License 2.0
A Lua port of the cassowary constraint solver engine
Home Page: https://luarocks.org/modules/simoncozens/cassowary
License: Apache License 2.0
Hey Simon sorry to bother you but we could use another release pushed to Luarocks. This time it is not a new version, it is just a new rockrel (-2) with only changes to the Luarocks packaging not the source. Hence it does not need a Git tag here in the repo. I've pushed the new rockrel already and you can find it on master. Internally it still references the tag for v2.3.1 in the repo for its source.
The difference is only in not forcing Luarocks v3 to use. It seems to work fine on legacy luarocks
and forcing the version is blocking using things like Ubuntu LTS releases to install this. We don't need any v3 only features so this seems to be for no gain.
In 44 commits since the last release almost nothing has changed in the substance of this library, but a lot has changed in the form. I'm working on getting downstream distro packaging cleaned up for this and there are quite a few issues (e.g. missing license) that would be resolved if we could tag and release a point release to Luarocks.
I'd be happy to handle the GitHub half, but per previous discussions (see Gitter here) LuaRocks doesn't play nicely with teams yet and @simoncozens you are the one with access there right now.
This one is less obvious than sile and libtexpdf and certainly not required but this could also be kept alongside SILE in the sile-typesetter
org. As I understand it the Lua module was first started as a helper for SILE, where it is a pretty settled requirement, and probably it's most active 'user'. I might not be a bad candidate to keep under that nasmespace as well. It won't restrict anybody using the Lua module independently.
My "issues with Busted" as chronicled in SILE issue 654 and Busted issue 609 actually seem to trace to the 1.1โ2.0 migration in this library swapping out stdlib with penlight.
Dropping the old version of this back into place (and fixing the paths so it is actually used by Busted) lets the tests pass again.
cassowary.lua use the stdlib module and use API that will be remove...
./cassowary.lua:35: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:332: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:344: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:531: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:543: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:615: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:616: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
./cassowary.lua:641: 'std.object.prototype' was deprecated in release 41.3, and will be removed entirely in a future release.
There is probably a new stdlib API as replacement of the 'std.object.prototype'.
Since Luarocks API keys are private one way to handle releases would be to setup a CI workflow that does the Luarocks push on tagged releases. This way the API key can stay protected as a CI secret but anyone with maintainer access could cut releases.
Gets an error when tracing is enabled.
lua: /usr/share/lua/5.3/cassowary.lua:684: attempt to concatenate a table value (field '?')
stack traceback:
/usr/share/lua/5.3/cassowary.lua:684: in method 'initializer'
/usr/share/lua/5.3/cassowary.lua:662: in field '_init'
/usr/share/lua/5.3/std/container.lua:174: in function </usr/share/lua/5.3/std/container.lua:156>
(...tail calls...)
main.lua:5: in main chunk
[C]: in ?
Currently the line is:
cassowary:tracePrint("objective expr == "..self.rows[self.objective])
It should be this instead:
cassowary:tracePrint("objective expr == "..tostring(self.rows[self.objective]))
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.