Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update data models #111

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Update data models #111

wants to merge 1 commit into from

Conversation

openactive-bot
Copy link
Contributor

Update PHP data models to the latest version based on the OpenActive Vocabulary (codified by the Data Models), Test Interface and Beta Namespace.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can't have a class called Class in PHP

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:)

DateTime::toISO8601() is also not a method, its just DateTime::ISO8601();

Erroneous line:

$sessionSeries->getStartDate()->toISO8601()

Docs ref: https://www.php.net/manual/en/class.datetimeinterface.php#datetimeinterface.constants.iso8601

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe the autoloader never loaded it because it was never used before?

<?php
// Try to make a class called Class

class Class 
{
    public function __construct()
    {
        echo 'hi';
    }
}

$myClass = new Class();

running this script gives: Parse error: syntax error, unexpected token "class", expecting identifier in class-test.php on line 4 expected output is hi.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make sense! Given the error was already here I wonder if we merge this PR and then solve this issue separately?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The 5.6 test is failing for a different reason (this one: #111 (comment)) to the 7.4 test.

But it seams reasonable to move the class thing to a new issue

@nickevansuk
Copy link
Contributor

I've created #112 which should allow this to pass?

@openactive-bot openactive-bot force-pushed the ci/update-data-models branch from dcde052 to 04a8a7b Compare June 20, 2024 10:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants