If you preview or save a release node right now in HEAD, there are a bunch of problems:

A) All kinds of PHP warnings from project_release_exists()

B) The version numbers you typed in are in fact gone after you preview.

C) The title isn't saved

D) File uploading is broken (should probably not even fix this and just work on #179471: release file attachments should use drupal upload functionality instead).

Comments

dww’s picture

Assigned: Unassigned » dww
Priority: Normal » Critical

Committed a fix for (A).
Working on (B) and (C) now.

hunmonk’s picture

Status: Active » Needs review
StatusFileSize
new28.44 KB

attached patch fixes up the basic file handling, and paves the way for multiple files per release node.

dww’s picture

Status: Needs review » Needs work

- Changes to project_release.install (which Chad's already got).

- Can't attach files to new release nodes, only while editing.

Will look at the rest of this when the above is fixed.

hunmonk’s picture

Status: Needs work » Needs review
StatusFileSize
new28.44 KB

k, those are fixed.

dww’s picture

Assigned: dww » hunmonk
Status: Needs review » Active

Chad committed that to HEAD. Back to active for (B), (C), and the fact that validation doesn't appear to be working right -- e.g. required fields are not actually required, etc.

hunmonk’s picture

StatusFileSize
new17.88 KB

here's another patch that fixes previews.

dww’s picture

Assigned: hunmonk » dww

We committed #6. However, there's still something broken with setting the version string (and therefore, the title of the node) when you submit. I'm working on this part.

dww’s picture

Status: Active » Needs work
StatusFileSize
new9.35 KB

Most of #7 was seriously broken by #98278: project* namespace bugs in $node and confusion about what kind of arguments project_release_get_version() expected. Fixed all that and added comments to hopefully prevent future bugs. Fixed some other problems, too.

2 known bugs:

A) If you edit an existing release node as an admin and try to change the title or version string, the new form values are never displayed on preview or saved to the DB on submit.

B) If you add a new release for a given API compatibility term and major version, the release download table on the project node doesn't seem to get rebuilt with the newer version.

dww’s picture

Status: Needs work » Active

Committed #8, working on the known bugs now.

dww’s picture

(B) Phew -- is due to #366163: {project_release_nodes} created with faulty data, not a bug in the code. ;)

Working on (A) now.

dww’s picture

Status: Active » Needs review
StatusFileSize
new1.58 KB

While working on #366448: Port packaging script to new {project_release_file} schema I discovered file_get_mimetype. ;) We should use that in this DB update.

dww’s picture

Status: Needs review » Fixed

I've fixed all this now and committed everything to HEAD.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.