Coder Social home page Coder Social logo

semanticapprovedrevs's Introduction

Semantic MediaWiki

CI Latest Stable Version Packagist download count

Semantic MediaWiki (a.k.a. SMW) is a free, open-source extension to MediaWiki โ€“ the wiki software that powers Wikipedia โ€“ that lets you store and query data within the wiki's pages.

Semantic MediaWiki is also a full-fledged framework, in conjunction with many spinoff extensions, that can turn a wiki into a powerful and flexible knowledge management system. All data created within SMW can easily be published via the Semantic Web, allowing other systems to use this data seamlessly.

For a better understanding of how Semantic MediaWiki works, have a look at deployed in 5 min and the Sesame, Fuseki triplestore video, or browse the wiki for a more comprehensive introduction.

Requirements

Semantic MediaWiki requires MediaWiki and its dependencies, such as PHP.

Supported MediaWiki, PHP and database versions depend on the version of Semantic MediaWiki. See the compatibility matrix for details.

Installation

The recommended way to install Semantic MediaWiki is by using Composer. See the detailed installation guide as well as the information on compatibility.

Documentation

Most of the documentation can be found on the Semantic MediaWiki wiki. A small core of documentation also comes bundled with the software itself. This documentation is minimalistic and less explanatory than what can be found on the SMW wiki. It is however always kept up to date, and applies to the version of the code it comes bundled with. The most important files are linked below.

Support

Chatroom Twitter Facebook LinkedIn YouTube Mailing lists

Primary support channels:

Contributing

Many people have contributed to SMW. A list of people who have made contributions in the past can be found here or on the wiki for Semantic MediaWiki. The overview on how to contribute provides information on the different ways available to do so.

If you want to contribute work to the project please subscribe to the developers mailing list and have a look at the contribution guidelines.

Tests

This extension provides unit and integration tests and are normally run by a continuous integration platform but can also be executed locally using the shortcut command composer phpunit from the extension base directory. A more comprehensive introduction can be found under the test section.

License

GNU General Public License, version 2 or later. The COPYING file explains SMW's copyright and license.

semanticapprovedrevs's People

Contributors

gesinn-it-gea avatar gesinn-it-wam avatar hexmode avatar kghbln avatar mwjames avatar translatewiki avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

semanticapprovedrevs's Issues

Make 1.0.0 release

Tracking issue for the 1.0.0 release.

  • Finalize RELEASE NOTES
  • Update "README.md"
  • Update "composer.json"
  • Update version number "extension.json"
  • Create tag
  • Add release to Wikidata
  • Update homepage
  • Announce via mail
  • Do a release tweet on Twitter
  • Run composer update on smw.o
  • Update "LocalSettings.php"
  • Start development of new version
    • Update "composer.json" (update dev alias)
    • Update "extension.json" (new alpha version)
  • Add extension to <doc.s-mw.o> SemanticMediaWiki/semantic-mediawiki.org#8

type error for params in ApprovedRevsHandler

Setup and configuration

  • SMW version: 3.1.5 (65a99ec)
  • SAR version: 0.1-alpha (8e30af0)
  • MW version: 1.34.4 (873590f)
  • DB: Percona 5.7.23-23-57-log

Issue

Seen in my exception log when jobs were running:

TypeError from line 68 of .../extensions/SemanticApprovedRevs/src/ApprovedRevsHandler.php: Argument 2 passed to SMW\ApprovedRevs\ApprovedRevsHandler::doChangeRevision() must be an instance of MediaWiki\Revision\RevisionStoreRecord or null, object given, called in .../extensions/SemanticApprovedRevs/src/Hooks.php on line 176

Looks similar to #23.

Get I18n via translatwiki rolling

  • 1) Add repo to user group with push rights - 2019-07-27
  • 2) Review "en.json" and extend "qqq.json" - 2019-07-29 #10
  • 3) Create pull to add extension to twn - 2019-07-30

For newly created pages, no annotations are created

Setup and configuration

  • SMW version: 4.x
  • AR 1.7.3, 1.8
  • SAR version: main
  • MW version: 1.35
  • DB (MySQL etc.): MySQL
  • Cache enabled or disabled (makes no difference)

Issue

For newly created pages, no annotations are created (Special.Browse) does not show anything. Even after approval, no annotations are created.

Steps to reproduce:

  • Create a new page that adds annotations via a template
  • Check Special:Browse to see, if any annotations has been created
  • Approve the page
  • Recheck Special:Browse to see, if any annotations has been created

MW 1.34+: SMW\ApprovedRevs\DatabaseLogReader::__construct() must be an instance of Wikimedia\Rdbms\Database

Setup and configuration

  • MediaWiki | 1.34.0-rc.0 (366bf66)22:03, 15 October 2019
  • PHP | 7.2.19-0ubuntu0.18.04.2 (apache2handler)
  • MariaDB | 10.1.41-MariaDB-0ubuntu0.18.04.1
  • Semantic MediaWiki | 3.2.0-alpha (c0b7a8f) 17:35, 14 October 2019
  • Semantic Extra Special Properties | 2.1.0-alpha (9606083) 07:37, 10 September 2019

Issue

When trying to run "rebuildElasticIndex.php" I get the following error:

TypeError from line 51 of /../w/extensions/SemanticApprovedRevs/src/DatabaseLogReader.php: Argument 1 passed to SMW\ApprovedRevs\DatabaseLogReader::__construct() must be an instance of Wikimedia\Rdbms\Database, instance of Wikimedia\Rdbms\MaintainableDBConnRef given, called in /../w/extensions/SemanticApprovedRevs/src/ServicesFactory.php on line 62

Backtrace

#0 /../w/extensions/SemanticApprovedRevs/src/ServicesFactory.php(62): SMW\ApprovedRevs\DatabaseLogReader->__construct(Wikimedia\Rdbms\MaintainableDBConnRef, NULL, string)
#1 /../w/extensions/SemanticApprovedRevs/src/ServicesFactory.php(71): SMW\ApprovedRevs\ServicesFactory->newDatabaseLogReader()
#2 /../w/extensions/SemanticApprovedRevs/src/PropertyAnnotator.php(81): SMW\ApprovedRevs\ServicesFactory->newApprovedByPropertyAnnotator()
#3 /../w/extensions/SemanticApprovedRevs/src/PropertyAnnotator.php(58): SMW\ApprovedRevs\PropertyAnnotator->initPropertyAnnotators()
#4 /../w/extensions/SemanticApprovedRevs/src/Hooks.php(224): SMW\ApprovedRevs\PropertyAnnotator->addAnnotation(SMW\SQLStore\EntityStore\StubSemanticData)
#5 /../w/includes/Hooks.php(174): SMW\ApprovedRevs\Hooks->onUpdateDataBefore(SMW\SQLStore\SQLStore, SMW\SQLStore\EntityStore\StubSemanticData)
#6 /../w/includes/Hooks.php(202): Hooks::callHook(string, array, array, NULL)
#7 /../w/extensions/SemanticMediaWiki/src/Store.php(234): Hooks::run(string, array)
#8 /../w/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php(409): SMW\Store->updateData(SMW\SQLStore\EntityStore\StubSemanticData)
#9 /../w/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php(349): SMW\Elastic\Indexer\FileIndexer->SMW\Elastic\Indexer\{closure}()
#10 /../w/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php(247): SMW\MediaWiki\Deferred\CallableUpdate->runUpdate()
#11 /../w/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/TransactionalCallableUpdate.php(168): SMW\MediaWiki\Deferred\CallableUpdate->doUpdate()
#12 /../w/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php(285): SMW\MediaWiki\Deferred\TransactionalCallableUpdate->doUpdate()
#13 /../w/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php(418): SMW\MediaWiki\Deferred\CallableUpdate->pushUpdate()
#14 /../w/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php(305): SMW\Elastic\Indexer\FileIndexer->addAnnotation(SMW\SQLStore\SQLStore, SMW\DIWikiPage)
#15 /../w/extensions/SemanticMediaWiki/src/Elastic/Indexer/Rebuilder.php(292): SMW\Elastic\Indexer\FileIndexer->index(SMW\DIWikiPage, ForeignAPIFile)
#16 /../w/extensions/SemanticMediaWiki/maintenance/rebuildElasticIndex.php(378): SMW\Elastic\Indexer\Rebuilder->rebuild(string, SMW\SQLStore\EntityStore\StubSemanticData)
#17 /../w/extensions/SemanticMediaWiki/maintenance/rebuildElasticIndex.php(335): SMW\Maintenance\RebuildElasticIndex->rebuild_row(string, stdClass, string, boolean)
#18 /../w/extensions/SemanticMediaWiki/maintenance/rebuildElasticIndex.php(163): SMW\Maintenance\RebuildElasticIndex->rebuild()
#19 /../w/maintenance/doMaintenance.php(99): SMW\Maintenance\RebuildElasticIndex->execute()
#20 /../w/extensions/SemanticMediaWiki/maintenance/rebuildElasticIndex.php(437): require_once(string)
#21 {main}

Composer Installation seems to be broken

Setup and configuration

  • SMW version: 3.2.3
  • SAR version: 1.0
  • MW version: 1.35
  • DB (MySQL etc.): 8.0.26

Issue

When trying to install the extension via composer, as specified in the documentation a error message is shown and the Installation doesn't take place.

composer.local.json entry:

"mediawiki/semantic-approved-revs": "~1.0"

Composer install command:

php composer.phar update --no-dev --prefer-source

Error Message:

Your requirements could not be resolved to an installable set of packages.

Problem 1
- The requested package mediawiki/semantic-approved-revs[dev-master, 0.1.x-dev] could not be found, it looks like its name is invalid, "[, ]" is not allowed in package names.

Potential causes:
- A typo in the package name
- The package is not available in a stable-enough version according to your minimum-stability setting
see https://getcomposer.org/doc/04-schema.md#minimum-stability for more details.
- It's a private package and you forgot to add a custom repository to find it

Internal Error when approving a wiki page

Setup and configuration

  • SMW version: 3.2.3
  • SAR version: 0.1-alpha (8e30af0)
  • MW version: 1.35.3
  • DB (MySQL etc.): MySQL 8.0.26-0ubuntu0.20.04.3
  • ApprovedRevs version: 1.6

Issue

When trying to approve a version of a page the following error appears:

[3c3c2a4e30d14bce2eb59797] /pmbd/index.php?title=Approvetest&action=approve&oldid=1358 TypeError from line 68 of /var/www/html/pmbd/extensions/SemanticApprovedRevs/src/ApprovedRevsHandler.php: Argument 2 passed to SMW\ApprovedRevs\ApprovedRevsHandler::doChangeRevision() must be an instance of MediaWiki\Revision\RevisionStoreRecord or null, object given, called in /var/www/html/pmbd/extensions/SemanticApprovedRevs/src/Hooks.php on line 176

Backtrace:

#0 /var/www/html/pmbd/extensions/SemanticApprovedRevs/src/Hooks.php(176): SMW\ApprovedRevs\ApprovedRevsHandler->doChangeRevision()
#1 /var/www/html/pmbd/includes/HookContainer/HookContainer.php(329): SMW\ApprovedRevs\Hooks->onChangeRevision()
#2 /var/www/html/pmbd/includes/HookContainer/HookContainer.php(132): MediaWiki\HookContainer\HookContainer->callLegacyHook()
#3 /var/www/html/pmbd/includes/Hooks.php(137): MediaWiki\HookContainer\HookContainer->run()
#4 /var/www/html/pmbd/extensions/SemanticMediaWiki/src/MediaWiki/HookDispatcher.php(251): Hooks::run()
#5 /var/www/html/pmbd/extensions/SemanticMediaWiki/src/MediaWiki/RevisionGuard.php(174): SMW\MediaWiki\HookDispatcher->onChangeRevision()
#6 /var/www/html/pmbd/extensions/SemanticMediaWiki/includes/ContentParser.php(200): SMW\MediaWiki\RevisionGuard->getRevision()
#7 /var/www/html/pmbd/extensions/SemanticMediaWiki/includes/ContentParser.php(144): SMW\ContentParser->getRevision()
#8 /var/www/html/pmbd/extensions/SemanticMediaWiki/includes/ContentParser.php(128): SMW\ContentParser->fetchFromContent()
#9 /var/www/html/pmbd/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/LinksUpdateConstructed.php(153): SMW\ContentParser->parse()
#10 /var/www/html/pmbd/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/LinksUpdateConstructed.php(143): SMW\MediaWiki\Hooks\LinksUpdateConstructed->reparseAndFetchSemanticData()
#11 /var/www/html/pmbd/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/LinksUpdateConstructed.php(97): SMW\MediaWiki\Hooks\LinksUpdateConstructed->updateSemanticData()
#12 /var/www/html/pmbd/extensions/SemanticMediaWiki/src/MediaWiki/Hooks.php(879): SMW\MediaWiki\Hooks\LinksUpdateConstructed->process()
#13 /var/www/html/pmbd/includes/HookContainer/HookContainer.php(329): SMW\MediaWiki\Hooks->onLinksUpdateConstructed()
#14 /var/www/html/pmbd/includes/HookContainer/HookContainer.php(132): MediaWiki\HookContainer\HookContainer->callLegacyHook()
#15 /var/www/html/pmbd/includes/HookContainer/HookRunner.php(2380): MediaWiki\HookContainer\HookContainer->run()
#16 /var/www/html/pmbd/includes/deferred/LinksUpdate.php(175): MediaWiki\HookContainer\HookRunner->onLinksUpdateConstructed()
#17 /var/www/html/pmbd/extensions/ApprovedRevs/includes/ApprovedRevs.php(551): LinksUpdate->__construct()
#18 /var/www/html/pmbd/extensions/ApprovedRevs/includes/ARApproveAction.php(39): ApprovedRevs::setApprovedRevID()
#19 /var/www/html/pmbd/includes/MediaWiki.php(527): ARApproveAction->show()
#20 /var/www/html/pmbd/includes/MediaWiki.php(313): MediaWiki->performAction()
#21 /var/www/html/pmbd/includes/MediaWiki.php(940): MediaWiki->performRequest()
#22 /var/www/html/pmbd/includes/MediaWiki.php(543): MediaWiki->main()
#23 /var/www/html/pmbd/index.php(53): MediaWiki->run()
#24 /var/www/html/pmbd/index.php(46): wfIndexMain()
#25 {main}

Argument 2 passed to SMW\ApprovedRevs\Hooks::onChangeRevision() must be an instance of Revision or null

Setup and configuration

  • SMW version: 4.0.0
  • AR: 1.7.3
  • SAR version: 0.9.1
  • MW version: 1.35
  • DB (MySQL etc.): MySQL

Issue

Produces an Internal Error on approve

[247416eeaad4471190c0c8c5] /index.php?title=Main_Page&action=approve&oldid=1 TypeError from line 172 of /var/www/html/extensions/SemanticApprovedRevs/src/Hooks.php: Argument 2 passed to SMW\ApprovedRevs\Hooks::onChangeRevision() must be an instance of Revision or null, instance of MediaWiki\Revision\RevisionStoreRecord given, called in /var/www/html/includes/HookContainer/HookContainer.php on line 329

Backtrace:

#0 /var/www/html/includes/HookContainer/HookContainer.php(329): SMW\ApprovedRevs\Hooks->onChangeRevision(Title, MediaWiki\Revision\RevisionStoreRecord)
#1 /var/www/html/includes/HookContainer/HookContainer.php(132): MediaWiki\HookContainer\HookContainer->callLegacyHook(string, array, array, array)

Steps to reproduce the observation:

  • Vanilla Wiki with default Main Page
  • Login as WikiSysop
  • Approve "Main Page"

File approval and file ingestion (`ElasticStore`)

Setup and configuration

  • SMW version: any
  • SAR version: any

Issue

When using the ElasticStore with the enabled file ingest option and a specific file version gets approved, support the reindexing (ingestion) of the approved file so that the correct (i.e. approved) file version (sha1) is indexed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.