OK, based on the discussion so far, we will add the data type to the snak in the external export, and keep the string data value for the URL data type. That should satisfy all use cases that have been brought up.
2013/9/2 Daniel Kinzler daniel.kinzler@wikimedia.de
Am 02.09.2013 00:57, schrieb Jeroen De Dauw:
Putting DT ids in DVs remains problematic, for the same reasons as before.
Luckily there are better alternatives then this approach.
Yes, I agree. The DT belongs to the Snak, not the DV. There are three models where we may want this:
- the canonical JSON (I say yes!)
- the PHP object (I say yes!)
- the internal JSON (probably yes, but let's think about it)
Thought needs to be put into how to best move DT into DataModel, and how
to best make use of it there. Before any concrete action is taken, we might want to have a close look at ValueValidators as well. This component has some open design issues, and will be introduced as a new dependency of DM if we move DTs there. Both of these concerns deserve their own discussions and are quite distinct from the current one (which is more about "what?" than "how?").
Note that we currently use the ValueValidator interface, but not the base class and none (?) of the default implementations. Wikibase/lib has its own validators. This may make it easier to find a good way to avoid dependencies.
-- daniel
______________________________**_________________ Wikidata-tech mailing list Wikidata-tech@lists.wikimedia.**org Wikidata-tech@lists.wikimedia.org https://lists.wikimedia.org/**mailman/listinfo/wikidata-techhttps://lists.wikimedia.org/mailman/listinfo/wikidata-tech