Releases: bitsteller/witica
1.2
Witica 1.2 released
Witica 1.2 improves performance and stability. A minor new feature is that you can now specify a minimum severity for the integrity issues listed by witica check
.
About Witica: Witica turns a folder in your Dropbox into a website. The goal is to make editing content on your website as easy as opening your favourite text editor, making a change and saving the file. Witica takes care of the rest.
Migration from previous releases
Update Witica
To update Witica on your machine execute:
pip install -U witica
When updating from 1.0: Re-Link with Dropbox
Because Dropbox changed the authentication process, you will need to re-link Witica to your Dropbox account at the first run. Watch the instructions in the terminal when running Witica for the first time.
Changes since 1.1
- NEW: added severity option to
witica check
- NEW: display warning when FTP disconnect fails
- NEW: added more unit tests for source
- CHANGE: improved performance when iterating through items in a source
- FIX: fixed an issue where witica does not continue after entering an FTP password
- FIX: FTP connection reconnecting randomly when uploading many files
v1.1
Witica 1.1 released
Witica 1.1 is a pure maintenance release. The main change compare to version 1.0 is the use of the new Dropbox API v2. An update is strongly recommended as the old Dropbox API will stop working in near future.
The update also includes a couple of bug fixes.
About Witica: Witica turns a folder in your Dropbox into a website. The goal is to make editing content on your website as easy as opening your favourite text editor, making a change and saving the file. Witica takes care of the rest.
Migration from previous releases
Update Witica
To update Witica on your machine execute:
pip install -U witica
Link to Dropbox
Because Dropbox changed the authentication process, you will need to re-link Witica to your Dropbox account at the first run. Watch the instructions in the terminal when running Witica for the first time.
Changes since 1.0.0
- CHANGE: Upgrade to Dropbox API v2
- CHANGE: If an image is smaller than the biggest requested variant, the original image is kept
- FIX: Removed unnecessary cache resets
v0.9.2 (Beta 2)
This version contains a reasonable number of bugfixes, cleanup & polishing. The most noticable change is the new item update detection in witica.js. It will detect changes quicker than before even though it is much more efficient when no changes are made to the target.
Other minor features include a new Witica.util.attachHumanReadableDate()
function to easily display a self-updating date string on a page and that you now can run the witica publisher also from subfolders of the source.
Migration from previous releases
Update witica.js
To benefit from the improvements in your existing targets in witica.js 0.9.2, like the new update mechanism, you need to run
witica upgrade
from within the source folder. It is also recommended to run
witica rebuild
after having upgraded all targets.
Use attachHumanReadableDate()
If you use Witica.util.getHumanReadableDate()
in your site.js, you should consider using the new Witica.util.attachHumanReadableDate()
instead. This new function can make any DOM element to contain a human readable date for the string that will update relative timesspans (like "2 minutes ago") automatically as time flows by.
Use style specific renderers
The supports
function passed to Witica.registerRenderer()
now also gets the render params passed besides the item. Sometimes you might want to write renderes that can handle different/all types of items, but only when a specific render parameter is passed. For example if you want to write a renderer for thumbnails, you can now write a dedicated thumbnail renderer that is used for all items, but only when a specific parameter in the render params is set. For example would
Witica.registerRenderer(ThumbnailRenderer, function (item, params) {return params.style == "thumbnail";});
register the renderer ThumbnailRenderer
for all items when the render param style is set to thumbnail.
v0.9.1 (Beta 1)
This version makes setting up a new website with Witica much easier than before. It removes the necessity of source files, instead you just run Witica from inside the source folder it should use. For the first time Witica can be installed with one command on the console using pip. In combination with the new witica init
command is now extremely easy to setup your first website with Witica.
Other major new features is the support to manage site specific code (html/js) through Witica, publishing to local folders and instant processing of changes from your Dropbox (previously it could take up to 30s before the change was detected).
With this release, Witica enters beta phase, which means that the witica.js API can be considered as more-or-less stable and the next releases won't introduce to much changes breaking with previous versions.
Migration from previous releases
Install using pip
In contrast to previous releases it is no longer necessary to run witica.py from the source distribution. Instead it is recommended to install the latest version using
pip install witica
Use witica support for uploading site scripts
With this version you don't need to upload the site scripts (index.html, site.js etc.) using an FTP client manually. Instead consider placing the files in a folder with the same name as the respective target inside the /meta directory of the source. Witica will upload all the files in this directory automatically to the server.
Set prefix paramter in Witica.initWitica() correctly
It is no longer necessary to have an "/" in the end of the prefix parameter. Instead of "target/" now use "target" for example. Also the target contents are now by default uploaded into a folder with the same name as the target. That means that in most cases the prefix
parameter should have the same name as the target id.
Remove code that still uses the old content access API
All deprecated functions in 0.8.5 of the old content access API have been removed and therefore code that still uses those function will stop working with 0.9.1.
v0.8.5 (Alpha 5)
This version introduces a greatly improved management of content files. It is now possible to generate different variants/size for images automatically and select the appropriate variant in witica.js. Among other small improvements to witica.js it is now possible to place the WebTarget in a dedicated folder on the server and initialise witica.js with that folder.
Note that some parts/functions are still incomplete or unstable. Also be aware that the syntax of the witica.js API can still change in upcoming releases, without backwards compatibility.
Drawbacks
The drawbacks in this version include particularly:
- the template for the website (client side) is not well commented
Migration from previous releases
New content handling
With the new content handling, Witica.Item.contentfiles
and Witica.Item.downloadContent()
are deprecated and will be removed in Alpha 6. Although they still work in Alpha 5 it is strongly recommended to migrate to the new content handling. If you have used Renderer.requireContent()
before, you need to be aware that the the syntax changed such that the first parameter is now a Witica.Content
object instead of a filename.
Instead of using Witica.Item.downloadContent()
or the new Witica.Content.download()
functions, it is now strongly recommended to use Renderer.requireContent()
whenever possible, as it makes sure that the request is aborted when the rendering is aborted. Instead of manually looping through the list of content files now Witica.Item.getContent()
and Renderer.requireContent()
provide much more convenient ways to get a content file with a specific extension.
See the witica.js documentation for more information.
Image variants
This version adds support for the automatic generation of image variants (different sizes). By default images will be generated in 3 different sizes (512, 1024, 2048 pixels) but you can change the defaults in the .target file of your WebTarget. You can also specify that the original image file should be uploaded too.
To use the appropriate size in each place, you should pass the needed minimal needed size to Witica.Content.getURL()
or Witica.Renderer.requireContentVariant()
.
View titles
This version allows to give every Witica.View
a title (by default this will be the title attribute of the item in the view if available). If a view is the Witica.mainView
, the document.title
of the web page will automatically be set to the title of the view. In 90% of the cases that means, if you previously set document.title
in a renderer, you can probably remove this code now, as Witica will do that automatically. To make debugging easier, Witica.View.toString()
will now give a tree with all the subviews in the view and their titles.
v0.8.4 (Alpha 4)
This version is a bugfix-only release that fixes some serious and minor issues that occurred in Alpha 3. This affected mainly the new relative links that were sometimes not working and the processing of metadata in witica.js which could return corrupted metadata for items.
Note that some parts/functions are still incomplete or unstable. Also be aware that the syntax of the witica.js API can still change in upcoming releases, without backwards compatibility.
Drawbacks
The drawbacks in this version include particularly:
- the template for the website (client side) is not well commented
Migration from previous releases
There are no API changes from 0.8.3 to 0.8.4. If you are upgrading from an earlier version please read the release notes for the releases in between.
v0.8.3 (Alpha 3)
This version changes the renderer initialisation flow and introduces native item references in metadata and relative references to other items (also in links and embeds). Other improvements include better error handling (witica.js), more integrity checks, better input validation (witica.py) and a number of bugfixes.
Note that some parts/functions are still incomplete or unstable. Also be aware that the syntax of the witica.js API can still change in upcoming releases, without backwards compatibility.
Drawbacks
The drawbacks in this version include particularly:
- the template for the website (client side) is not well commented
Migration from previous releases
The following aspects should be considered before upgrading to the v0.8.3 from v.0.8.2:
New initialisation process for renderers
You need to change your code if you previously used the arguments previousRenderer/nextRenderer that were passed to the render()/unrender() function. Now instead only the item to render/unrender is passed. Consider moving code to an init() or deinit() function, that now get previousRenderer/nextRenderer passed as an argument.
When constructing a renderer the view
is still passed, but it is recommended to remove all code that depends on knowing the view from the constructor and moving it to an init() function, where the view is available. Passing view
to the constructor is deprecated.
Here is a list of things to consider:
- renderer constructors should no longer assume that the view is already known, instead wait until init() is called
- the sequence called over a renderers lifetime is now: init()->render()->unrender()…->render()->unrender()->deinit()
- init() is passed the previous renderer, deinit() the next renderer
- render() and unrender() is now passed the item instead of previous/next renderer
- it is now possible that a renderer inherits from another renderer via prototypes
New item references in metadata
If you reference items in metadata you should now use the new native item references, defined by a string of the format !item_id
. Values of this type in metadata will now show up as a Witica.Item
object when accessed through Witica.Item.metadata
.
v0.8.2 (Alpha 2)
This version features improvements to the witica.js client library, greatly improved documentation and a number of smaller changes and bugfixes.
Note that some parts/functions are still incomplete or unstable. Also be aware that the syntax of the witica.js API can still change in upcoming releases, without backwards compatibility.
Drawbacks
The drawbacks in this version include particularly:
- the template for the website (client side) is not well commented
- cache data is saved in the program folder (when executing witica.py)
v0.8.1 (Alpha 1)
This is a first public alpha of Witica.
Note that some parts/functions are still incomplete or unstable. Also be aware that the syntax of the witica.js API can still change in upcoming releases, without backwards compatibility.
Drawbacks
The drawbacks in this version include particularly:
- the documentation (client API) is incomplete
- the template for the website (client side) is not well commented
- cache data is saved in the program folder (when executing witica.py)
- render parameters are included as text inside the document when embedding, which are visible in the browser until loadSubviews() is called