VDVde / OJP

Open API for distributed journey planning. CEN/TS 17118:2017.
https://www.vdv.de/open-journey-planner.aspx
22 stars 12 forks source link

Use SIRI v2.1 from upstream as git submodule #329

Closed skinkie closed 1 year ago

skinkie commented 1 year ago

At least try if this would work.

skinkie commented 1 year ago

@sgrossberndt I guess we miss a git submodule update --init in our github actions.

skinkie commented 1 year ago

@ue71603 feel free to update the examples that now fail.

skinkie commented 1 year ago

I have some doubts my last commit changing to "../SIRI" is correct.

When checking what goes wrong;

examples/switzerland/Trip_001_Response.xml:8: element OJPTripDelivery: Schemas validity error : Element '{http://www.vdv.de/ojp}OJPTripDelivery': This element is not expected. Expected is one of ( {http://www.siri.org.uk/siri}ErrorCondition, {http://www.siri.org.uk/siri}MoreData, {http://www.siri.org.uk/siri}IncludedSituationExchangeDelivery, {http://www.siri.org.uk/siri}ProductionTimetableDelivery, {http://www.siri.org.uk/siri}EstimatedTimetableDelivery, {http://www.siri.org.uk/siri}StopTimetableDelivery, {http://www.siri.org.uk/siri}StopMonitoringDelivery, {http://www.siri.org.uk/siri}VehicleMonitoringDelivery, {http://www.siri.org.uk/siri}ConnectionTimetableDelivery, {http://www.siri.org.uk/siri}ConnectionMonitoringFeederDelivery ).

I don't know yet what is actually 'missing' but if any delivery would work, I don't see why any AbstractFunctionalServiceDelivery does not.

./OJP/OJP_Requests.xsd: <xs:element name="OJPTripDelivery" type="OJPTripDeliveryStructure" substitutionGroup="siri:AbstractFunctionalServiceDelivery"/>
ue71603 commented 1 year ago

git for Desktop was not able to switch to the branch and messed up my local repository. Had to

Which is clear, as it no longer does the automatic copying of SIRI.

Perhaps some part of this is needed to copy the data into the folder: https://stackoverflow.com/questions/11069651/setting-upstream-to-a-submodule-or-how-to-include-a-github-fork-as-a-submodule

Currently it is clear why the tests are not running: No SIRI available locally.

skinkie commented 1 year ago

@ue71603 just to try it, can you manually clone SIRI in the SIRI subfolder, and see if you can get the files validating?

ue71603 commented 1 year ago

@skinkie

Afterwards it validated. I try to do a PR (will add the full master of siri into the PR

skinkie commented 1 year ago

On Monday, March 6, 2023 8:38:14 PM CET, Matthias Günter wrote:

@skinkie

  • fixing OJP.xsd als with switching the import to <xs:include schemaLocation="./SIRI/xsd/siri_model/siri_all.xsd"/>

Can you please check if it is ../SIRI or it should be ./SIRI?

-- Stefan

skinkie commented 1 year ago

@ue71603 does not work at my side.

ue71603 commented 1 year ago

OJP.xsd is one level higher, so there it is only "./siri...." in the others it is "../siri"

skinkie commented 1 year ago

@ue71603 @sgrossberndt need two acknowledges ;-)

sgrossberndt commented 1 year ago

I have issues on my setup with this branch because of the former directory name "siri" and new directory name "SIRI". I propose to change the directory name back to "siri". What do you think?

sgrossberndt commented 1 year ago

You have to run git submodule init ./siri in order to fetch the SIRI sources

skinkie commented 1 year ago

What do you think?

...annoying windows users.

ue71603 commented 1 year ago

What do you think?

...annoying windows users.

the worst....

ue71603 commented 1 year ago

You have to run git submodule init ./siri in order to fetch the SIRI sources

didn't fetch anything and I had to install git in addition to do it.

ue71603 commented 1 year ago

All suggestions up to now don't work for me. And I am sorry, I need to do work on the functional stuff this month and can't affort to break the tool chain. I suggest we use a copied version of siri 2.1 for now and deal with this PR afterwards. I will even rebase it then. Having it done as a pipeline is not on the criticial path for this project. Stefan, I apologize for asking to do it first.

ue71603 commented 1 year ago

Things I had to do... https://github.com/VDVde/OJP/wiki/Working-with-the-submodule and I am not sure, if everybody can do it (one needs to install git, too.

ue71603 commented 1 year ago

...and I think we need a discussion, why an automatic upstream is a good idea for this type of project...