• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Won't fix Missing Zend Components

digitalpoint

Well-known member
#1
While I know it's not technically a bug since it doesn't affect things that XenForo uses, there are some Zend components that are included that have dependencies that are not included in the XF distribution.

I haven't checked it exhaustively, but I'm building something that requires the Twitter API... so I was like, "Sweets, I'll just use the Twitter API class that is included with Zend and already installed with XenForo..."

Unfortunately there is no Zend/Rest/ directory so you can't load the Zend_Service_Twitter class...
Fatal error: main() [function.require]: Failed opening required 'Zend/Rest/Client.php'
Any reason parts of Zend the framework were left out? And if it was simply because it's not something XF uses, why are some of the classes included that XF also doesn't use (for example the Twitter one).
 

digitalpoint

Well-known member
#3
It's easy enough to install the Rest directory (which I did)... just going to be rather annoying keeping it in sync if they update the Zend framework version they are using.

Streamlining is fine and all, but if that's the intent, you could streamline it further by removing components that have dependencies on the ones you already removed.
 

Robbo

Well-known member
#4
The Zend framework they are using is indeed a version that is striped down to only contain what they need for XenForo or see as useful. I doubt this will change, just add what Zend components you need when you need them.
 

Jeremy

Well-known member
#5
Robbo, the point wasn't that its stripped down. The point was that Zend_Service_Twitter was available in the package and for him to use, however, its dependencies weren't. I am fairly sure it'd be useful to just include the entire library.
 

robdog

Well-known member
#6
I would like them just to include the whole Zend framework package. It is not that big of a deal to upload this whenever you need to do an upgrade. Would definitely make it easier to do certain modifications.

However, we could just keep track of WHICH Zend version each XenForo version is on and upload the entire package independently.
 

Mike

XenForo developer
Staff member
#7
The whole package is much bigger than what we've shipped. I've only stripped out entire top level packages, nothing within that (except for the locales). We use some stuff in Zend_Service, so I'm not stripping out elements from within there.

We could probably leave the REST client, but I'm not trying to get into complex dependency management. We're just trying to keep the upload a bit simpler for those people that have to use FTP to upload it. :)

If you want other parts of ZF for your use, the safest bet is probably to provide them.
 

digitalpoint

Well-known member
#8
Yep... at this point all I needed to add was the Rest components. I'm mostly just worried if you guys update the version of the Zend Framework you are using, stuff might break if the Rest stuff is from an older version.

I guess if you guys *do* update the Zend framework version, any chance of getting a note that it was updated in the release post or something?
 

Robbo

Well-known member
#9
I doubt any changes to the 1.x line will mess with any definitions, just maintenance releases. You shouldn't have anything to worry about.

I do hope after ZF 2 comes outand XenForo is well established they start making 2.0 with namespaces etc using ZF 2.
 

Robbo

Well-known member
#10
I take this back ^. All of it. But I guess having it smaller is a bigger benefit for you and Zend is pretty bad anyway.

And to my last reply, I hope XenForo doesn't use Zend at all in the 2.x branch!