https://www.redmine.org/https://www.redmine.org/favicon.ico?16793021292021-01-25T08:48:04ZRedmineRedmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1006822021-01-25T08:48:04ZIvan Cenov
<ul></ul><p>Environment</p>
<blockquote>
<p>Redmine version 3.4.4.devel<br />Ruby version 2.4.1-p111 (2017-03-22) [x86_64-linux]<br />Rails version 5.1.4<br />Environment production<br />Database adapter Mysql2</p>
</blockquote> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1006842021-01-25T11:13:08ZMischa The Evil
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>Confirmed</i></li><li><strong>Assignee</strong> set to <i>Mischa The Evil</i></li></ul><p>Thanks for opening this issue. I've been reading along and it already got me curious, so I already had a look at the source. I can confirm the reported behavior (at least partially, as far as I've tested). Along the way I found several other issues too.<br />I'm working on providing a patch.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1007112021-01-27T09:02:07ZMischa The Evil
<ul><li><strong>Related to</strong> <i><a class="issue tracker-3 status-5 priority-4 priority-default closed" href="/issues/34643">Patch #34643</a>: Cleanups and fixes after Wiki tab removal from project settings (#26579)</i> added</li></ul> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1007122021-01-27T09:22:16ZMischa The Evil
<ul><li><strong>Category</strong> set to <i>Wiki</i></li><li><strong>Assignee</strong> changed from <i>Mischa The Evil</i> to <i>Ivan Cenov</i></li></ul><p>Ivan Cenov wrote:</p>
<blockquote>
<p>An user delete all wiki pages including the root page. Then he could not see the root page and could not create wiki pages any more.</p>
</blockquote>
<p>Mischa The Evil wrote:</p>
<blockquote>
<p>I can confirm the reported behavior (at least partially, as far as I've tested).</p>
</blockquote>
<p>I confirm this is a problem when a whole <em>project wiki</em> is deleted. I don't see this being a problem when deleting <em>single</em> <em>wiki pages</em>.<br /><a class="user active" href="https://www.redmine.org/users/3676">Ivan Khrustalev</a>: can you too confirm this (also with the OP of <a class="message" href="https://www.redmine.org/boards/2/topics/61955">Can't add deleted wiki Tab. (404)</a>)?</p>
<p>I have posted a patch that fixes this case as part of <a class="issue tracker-3 status-5 priority-4 priority-default closed" title="Patch: Cleanups and fixes after Wiki tab removal from project settings (#26579) (Closed)" href="https://www.redmine.org/issues/34643">#34643</a> (file: 4. Disable the wiki module after deletion of a project wiki.). It should be applicable on its own.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1007132021-01-27T09:22:35ZMischa The Evil
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/100713/diff?detail_id=81633">diff</a>)</li></ul> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1033452021-07-26T21:37:14ZMarius BĂLTEANU
<ul><li><strong>File</strong> <a href="/attachments/27775">0004-Disable-the-wiki-module-after-deletion-of-a-project-.patch</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/27775/0004-Disable-the-wiki-module-after-deletion-of-a-project-.patch">0004-Disable-the-wiki-module-after-deletion-of-a-project-.patch</a> added</li><li><strong>Assignee</strong> changed from <i>Ivan Cenov</i> to <i>Mischa The Evil</i></li><li><strong>Target version</strong> set to <i>5.0.0</i></li></ul><p>I've extracted the patch proposed by Mischa The Evil in <a class="issue tracker-3 status-5 priority-4 priority-default closed" title="Patch: Cleanups and fixes after Wiki tab removal from project settings (#26579) (Closed)" href="https://www.redmine.org/issues/34643">#34643</a>:</p>
<blockquote>
<ul>
<li><strong>4. Disable the wiki module after deletion of a project wiki.</strong><br />By adding a (private) <code>after_destroy</code> <code>:disable_wiki_module</code> callback that disables the wiki module after deletion of a project wiki, we prevent the need to explicitly have to disable the wiki module first, before (re-)enabling the module would eventually create a new project wiki and reset the <code>start_page</code>.</li>
</ul>
</blockquote>
<p>I still think that it's a good ideea to inform the user that deleting the wiki root page will automatically disable the module.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1033552021-07-27T03:19:32ZMischa The Evil
<ul></ul><p>Marius BALTEANU wrote:</p>
<blockquote>
<p>I still think that it's a good ideea to inform the user that deleting the wiki root page will automatically disable the module.</p>
</blockquote>
<p>Sure. However, now that I have had a second look at this, I think that disabling the module after the deletion is a bit of an ugly workaround. A better solution would be to implement something like a 'no data' message when a project wiki is missing and add a way for users with the required permission(s) to reinstate a new wiki by just letting them add new pages from the front-end while creating a new project wiki in the background automatically if one is not yet available. That would also take away the need for an additional notification message. What do you think?</p>
<p>Btw: I think you got it but to be certain, when you wrote <cite>...deleting the wiki root page...</cite> -> it's actually about deleting the project's wiki itself. I've written about this is more detail in <a class="message" href="https://www.redmine.org/boards/2/topics/61955?r=61992#message-61992">RE: Can't add deleted wiki Tab. (404)</a>.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1060772022-03-21T21:45:18ZMarius BĂLTEANU
<ul><li><strong>File</strong> <a href="/attachments/28991">34634.patch</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/28991/34634.patch">34634.patch</a> added</li><li><strong>Assignee</strong> deleted (<del><i>Mischa The Evil</i></del>)</li></ul><p>What do you think if we create a new empty Wiki after deletion?</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1061812022-03-27T21:17:45ZMarius BĂLTEANU
<ul><li><strong>Target version</strong> changed from <i>5.0.0</i> to <i>5.1.0</i></li></ul> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1109842023-10-15T04:23:08ZMischa The Evil
<ul></ul><p>Marius BALTEANU wrote in <a href="#note-8">#note-8</a>:</p>
<blockquote>
<p>What do you think if we create a new empty Wiki after deletion?</p>
</blockquote>
<p>FWIW: I think that'll work too. Though, for clarity it might be better to change the name of the proposed class method <code>Wiki.create_default_page</code> to something more generic like just <code>Wiki.create_default</code> since we're actually creating a <code>Wiki</code> object, not an object associated with wiki pages (i.e. <code>WikiPage</code>).</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1110242023-10-21T01:00:13ZGo MAEDA
<ul><li><strong>Target version</strong> changed from <i>5.1.0</i> to <i>6.0.0</i></li></ul> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1110342023-10-21T10:38:11ZMarius BĂLTEANU
<ul></ul><p>Thanks for your feedback, Mischa. I will try to catch this in <a class="version" href="https://www.redmine.org/versions/176">5.1.0</a>.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1110682023-10-23T17:35:42ZMarius BĂLTEANU
<ul><li><strong>Status</strong> changed from <i>Confirmed</i> to <i>Resolved</i></li><li><strong>Assignee</strong> set to <i>Marius BĂLTEANU</i></li><li><strong>Target version</strong> changed from <i>6.0.0</i> to <i>5.1.0</i></li><li><strong>Resolution</strong> set to <i>Fixed</i></li></ul><p>I've committed the patch that reinitialise an empty wiki page after the project wiki is deleted. I don't see really necessary to have an extra message for this.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1110772023-10-23T23:41:17ZMischa The Evil
<ul><li><strong>Status</strong> changed from <i>Resolved</i> to <i>Closed</i></li></ul><p>Marius BALTEANU wrote in <a href="#note-13">#note-13</a>:</p>
<blockquote>
<p>I've committed the patch that reinitialise an empty wiki page after the project wiki is deleted. I don't see really necessary to have an extra message for this.</p>
</blockquote>
<p>Thanks! And I agree with you that an additional message would be unnecessary.</p> Redmine - Defect #34634: Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivationhttps://www.redmine.org/issues/34634?journal_id=1112382023-10-29T01:11:20ZMischa The Evil
<ul><li><strong>Subject</strong> changed from <i>Can't add deleted wiki Tab (404)</i> to <i>Deletion of project wiki leaves the project wiki inaccessible (404) until module reactivation</i></li></ul><p>Change subject for changelog clarity.</p>